[PHP-CVS-DAILY] cvs: php-src / ChangeLog

2009-04-30 Thread changelog
changelog   Fri May  1 01:32:51 2009 UTC

  Modified files:  
/php-srcChangeLog 
  Log:
  ChangeLog update
  
http://cvs.php.net/viewvc.cgi/php-src/ChangeLog?r1=1.3389r2=1.3390diff_format=u
Index: php-src/ChangeLog
diff -u php-src/ChangeLog:1.3389 php-src/ChangeLog:1.3390
--- php-src/ChangeLog:1.3389Thu Apr 30 01:32:42 2009
+++ php-src/ChangeLog   Fri May  1 01:32:50 2009
@@ -1,3 +1,135 @@
+2009-04-30  Antony Dovgal  t...@daylessday.org
+
+* (PHP_5_2)
+  ext/standard/tests/versioning/php_sapi_name_variation001.phpt:
+  fix test (for real)
+
+2009-04-30  Pierre-Alain Joye  pierre@gmail.com
+
+* ext/imap/php_imap.c
+  ext/imap/php_imap.c:
+  - MFB: #47940, memory leaks in imap_body
+
+* (PHP_5_2)
+  NEWS
+  ext/imap/php_imap.c:
+  - #47940, memory leaks in imap_body
+
+2009-04-30  Ilia Alshanetsky  i...@prohost.org
+
+* (PHP_5_2)
+  NEWS:
+  
+  Fixed typo
+
+2009-04-30  Pierre-Alain Joye  pierre@gmail.com
+
+* (PHP_5_2)
+  NEWS:
+  - 45997
+
+* (PHP_5_3)
+  ext/standard/exec.c:
+  - MFB: #45997, safe_mode bypass with exec/sytem/passthru (windows only)
+
+* (PHP_5_2)
+  ext/standard/exec.c:
+  - #45997, safe_mode bypass with exec/sytem/passthru (windows only)
+
+2009-04-30  Jani Taskinen  jani.taski...@sci.fi
+
+* ext/standard/tests/mail/mail_variation2.phpt:
+  Fix test
+
+* ext/standard/tests/mail/mail_basic2.phpt:
+  -Fix test
+
+* (PHP_5_2)
+  ext/standard/tests/versioning/php_sapi_name_variation001.phpt:
+  - Fix test: It is still possible to enable/disable fastcgi in PHP_5_2
+
+2009-04-30  Matteo Beccati  mat...@beccati.com
+
+* (PHP_5_3)
+  ext/pdo_pgsql/config.w32
+  ext/pdo_pgsql/pgsql_driver.c:
+  MFH:
+  - Removed HAVE_PQEXECPARAMS which was left out during the previous commit
+
+* ext/pdo_pgsql/config.w32
+  ext/pdo_pgsql/pgsql_driver.c:
+  - Removed HAVE_PQEXECPARAMS which was left out during the previous commit
+
+* (PHP_5_3)
+  ext/pdo_pgsql/config.m4
+  ext/pdo_pgsql/config.w32
+  ext/pdo_pgsql/pgsql_driver.c
+  ext/pdo_pgsql/pgsql_statement.c
+  ext/pdo_pgsql/php_pdo_pgsql_int.h:
+  MFH:
+  - Changed PDO_PGSQL configure script to require libpq 7.4
+  - Cleaned up usage of HAVE_PQ* defines
+  - Fixed compiler warnings
+  - Removed custom implementation of PQunescapeByte
+
+* ext/pdo_pgsql/config.m4
+  ext/pdo_pgsql/config.w32
+  ext/pdo_pgsql/pgsql_driver.c
+  ext/pdo_pgsql/pgsql_statement.c
+  ext/pdo_pgsql/php_pdo_pgsql_int.h:
+  - Changed PDO_PGSQL configure script to require libpq 7.4
+  - Cleaned up usage of HAVE_PQ* defines
+  - Fixed compiler warnings
+  - Removed custom implementation of PQunescapeByte
+
+2009-04-30  Jani Taskinen  jani.taski...@sci.fi
+
+* (PHP_5_2)
+  ZendEngine2/tests/bug39018.phpt
+  ZendEngine2/tests/bug39018_2.phpt:
+  - Added missing tests from this branch..*sigh*
+
+* (PHP_5_2)
+  tests/classes/inheritance_007.phpt:
+  - Reflection can be disabled in PHP_5_2
+
+* (PHP_5_2)
+  ext/curl/tests/bug45161.phpt
+  ext/curl/tests/bug46711.phpt:
+  - Fix test + add missing test
+
+* ext/curl/tests/bug45161.phpt
+  ext/curl/tests/bug46711.phpt
+  ext/curl/tests/bug46711.phpt:
+  - Add missing test
+
+* (PHP_5_2)
+  ext/date/tests/DateTimeZone_verify.phpt
+  ext/date/tests/DateTime_verify.phpt
+  ext/soap/tests/bugs/bug41477.phpt:
+  - It is possible to disable reflection extension in PHP_5_2
+
+2009-04-30  Pierre-Alain Joye  pierre@gmail.com
+
+* main/main.c
+  main/main.c:
+  - fix build (Marcus, fix re2c please)
+
+2009-04-30  Greg Beaver  g...@chiaraquartet.net
+
+* (PHP_5_3)
+  NEWS
+  ext/phar/phar.c
+  ext/phar/tests/phar_construct_invalidurl.phpt:
+  MFPECL fix PECL Bug #14646: phar error message unclear with php stream
+  wrappers (note: is there a standard way to list PECL bugs in NEWS?)
+
+* ext/phar/phar.c
+  ext/phar/tests/phar_construct_invalidurl.phpt
+  ext/phar/tests/phar_construct_invalidurl.phpt:
+  MFPECL: fixed PECL Bug #14646: phar error message unclear with php stream
+  wrappers
+
 2009-04-29  Ilia Alshanetsky  i...@prohost.org
 
 * (PHP_5_2)
@@ -37828,7 +37960,7 @@
 
 * sapi/litespeed/lsapi_main.c
   sapi/litespeed/lsapilib.c:
-  - Added missing $Id: ChangeLog,v 1.3389 2009/04/30 01:32:42 changelog 
Exp $ tags and nuked c++ comments
+  - Added missing $Id: ChangeLog,v 1.3390 2009/05/01 01:32:50 changelog 
Exp $ tags and nuked c++ comments
 
 * (PHP_5_3)
   ext/intl/locale/locale.c




[PHP-CVS-DAILY] cvs: ZendEngine2 / ChangeLog

2009-04-30 Thread changelog
changelog   Fri May  1 01:32:56 2009 UTC

  Modified files:  
/ZendEngine2ChangeLog 
  Log:
  ChangeLog update
  
http://cvs.php.net/viewvc.cgi/ZendEngine2/ChangeLog?r1=1.1475r2=1.1476diff_format=u
Index: ZendEngine2/ChangeLog
diff -u ZendEngine2/ChangeLog:1.1475 ZendEngine2/ChangeLog:1.1476
--- ZendEngine2/ChangeLog:1.1475Tue Apr 28 01:33:00 2009
+++ ZendEngine2/ChangeLog   Fri May  1 01:32:55 2009
@@ -1,3 +1,10 @@
+2009-04-30  Jani Taskinen  jani.taski...@sci.fi
+
+* (PHP_5_2)
+  tests/bug39018.phpt
+  tests/bug39018_2.phpt:
+  - Added missing tests from this branch..*sigh*
+
 2009-04-27  Felipe Pena  felipe...@gmail.com
 
 * (PHP_5_2)
@@ -28504,7 +28511,7 @@
 2003-06-10  Jani Taskinen  sni...@iki.fi
 
 * zend_multiply.h:
-  - Missing $Id: ChangeLog,v 1.1475 2009/04/28 01:33:00 changelog Exp $ tag
+  - Missing $Id: ChangeLog,v 1.1476 2009/05/01 01:32:55 changelog Exp $ tag
 
 2003-06-10  James Cox  ja...@imajes.info
 
@@ -30228,7 +30235,7 @@
   zend_types.h
   zend_variables.c
   zend_variables.h:
-  - Added some missing CVS $Id: ChangeLog,v 1.1475 2009/04/28 01:33:00 
changelog Exp $ tags, headers and footers.
+  - Added some missing CVS $Id: ChangeLog,v 1.1476 2009/05/01 01:32:55 
changelog Exp $ tags, headers and footers.
 
 2003-01-30  Ilia Alshanetsky  i...@prohost.org
 




[PHP-CVS] cvs: phpruntests /src rtClassMap.php /src/testcase/sections/configurationsections rtGzipPostSection.php /tests/testcase/sections/configurationsections rtGzipPostSectionTest.php

2009-04-30 Thread Zoe Slattery
zoe Thu Apr 30 08:12:32 2009 UTC

  Added files: 
/phpruntests/tests/testcase/sections/configurationsections  

rtGzipPostSectionTest.php 

  Modified files:  
/phpruntests/src/testcase/sections/configurationsections

rtGzipPostSection.php 
/phpruntests/srcrtClassMap.php 
  Log:
  fixes to gzip_post section and a test case
  
http://cvs.php.net/viewvc.cgi/phpruntests/src/testcase/sections/configurationsections/rtGzipPostSection.php?r1=1.1r2=1.2diff_format=u
Index: 
phpruntests/src/testcase/sections/configurationsections/rtGzipPostSection.php
diff -u 
phpruntests/src/testcase/sections/configurationsections/rtGzipPostSection.php:1.1
 
phpruntests/src/testcase/sections/configurationsections/rtGzipPostSection.php:1.2
--- 
phpruntests/src/testcase/sections/configurationsections/rtGzipPostSection.php:1.1
   Wed Apr 29 18:51:33 2009
+++ 
phpruntests/src/testcase/sections/configurationsections/rtGzipPostSection.php   
Thu Apr 30 08:12:32 2009
@@ -12,7 +12,7 @@
  * @license   http://www.php.net/license/3_01.txt PHP License 3.01
  * @link  http://qa.php.net/
  */
-class rtPostSection extends rtConfigurationSection
+class rtGzipPostSection extends rtConfigurationSection
 {
 private $postVariables = array();
 private $postFileName;
@@ -21,13 +21,14 @@
 { 
 $postString = implode('\n', $this-sectionContents);
 $gzipPostString = gzencode($postString);
+
 $this-postVariables['CONTENT_TYPE'] = 
'application/x-www-form-urlencoded';
 $this-postVariables['CONTENT_LENGTH'] = strlen($gzipPostString);
 $this-postVariables['REQUEST_METHOD'] = 'POST';
 
 $this-postFileName = tempnam(sys_get_temp_dir(), 'post');
 
-file_put_contents($this-postFileName, $postString);
+file_put_contents($this-postFileName, $gzipPostString);
 }
 
 /**
http://cvs.php.net/viewvc.cgi/phpruntests/src/rtClassMap.php?r1=1.3r2=1.4diff_format=u
Index: phpruntests/src/rtClassMap.php
diff -u phpruntests/src/rtClassMap.php:1.3 phpruntests/src/rtClassMap.php:1.4
--- phpruntests/src/rtClassMap.php:1.3  Mon Apr 27 21:05:33 2009
+++ phpruntests/src/rtClassMap.php  Thu Apr 30 08:12:32 2009
@@ -58,6 +58,7 @@
 'rtArgsSection'= 
'testcase/sections/configurationsections/rtArgsSection.php',
 'rtEnvSection' = 
'testcase/sections/configurationsections/rtEnvSection.php',
 'rtGetSection' = 
'testcase/sections/configurationsections/rtGetSection.php',
+'rtGzipPostSection'= 
'testcase/sections/configurationsections/rtGzipPostSection.php',
 'rtIniSection' = 
'testcase/sections/configurationsections/rtIniSection.php',
 'rtPostSection'= 
'testcase/sections/configurationsections/rtPostSection.php',
 'rtCleanSection'   = 
'testcase/sections/executablesections/rtCleanSection.php',

http://cvs.php.net/viewvc.cgi/phpruntests/tests/testcase/sections/configurationsections/rtGzipPostSectionTest.php?view=markuprev=1.1
Index: 
phpruntests/tests/testcase/sections/configurationsections/rtGzipPostSectionTest.php
+++ 
phpruntests/tests/testcase/sections/configurationsections/rtGzipPostSectionTest.php
?php
require_once 'PHPUnit/Framework.php';
require_once dirname(__FILE__) . '../../../../../src/rtAutoload.php';

class rtGzipPostSectionTest extends PHPUnit_Framework_TestCase
{
public function testCreateInstance() 
{
$postSection = new rtGzipPostSection('GZIP_POST', 
array('hello=Worldgoodbye=MrChips'));  

$envVars = $postSection-getPostVariables();
$this-assertEquals('POST', $envVars['REQUEST_METHOD']);

$this-assertEquals('application/x-www-form-urlencoded',$envVars['CONTENT_TYPE']);
$this-assertEquals(strlen(gzencode('hello=Worldgoodbye=MrChips')), 
$envVars['CONTENT_LENGTH']);

$fileName = $postSection-getPostFileName();
$string = file_get_contents($fileName);

$expectedString = gzencode('hello=Worldgoodbye=MrChips');

$this-assertEquals($expectedString, $string);
}
}
?


-- 
PHP CVS Mailing List (http://www.php.net/)
To unsubscribe, visit: http://www.php.net/unsub.php



[PHP-CVS] cvs: CVSROOT / avail

2009-04-30 Thread Philip Olson
philip  Thu Apr 30 08:51:42 2009 UTC

  Modified files:  
/CVSROOTavail 
  Log:
  GSoC karma as requested by the associated mentors. 
  php-benchmarks for Alexander Hjalmarsson (hjalle) and doc-editor for Chan Ka 
Shing (mrkschan)
  
  
http://cvs.php.net/viewvc.cgi/CVSROOT/avail?r1=1.1518r2=1.1519diff_format=u
Index: CVSROOT/avail
diff -u CVSROOT/avail:1.1518 CVSROOT/avail:1.1519
--- CVSROOT/avail:1.1518Tue Apr 21 07:32:05 2009
+++ CVSROOT/avail   Thu Apr 30 08:51:41 2009
@@ -33,7 +33,7 @@
 
 # Some people only work on PhD (The DocBook [manual] build system)
 # Those with php-src and/or phpdoc karma already have access to this
-avail|loudi,cweiske|phd,docweb,doc-editor
+avail|loudi,cweiske,mrkschan|phd,docweb,doc-editor
 
 # People who work on the Engine - not people with just tests access
 
avail|andi,zeev,andrei,stas,sterling,sascha,derick,sebastian,phanto,jani,hirokawa,fujimoto,rvenkat,sesser,kalowsky,iliaa,hyanantha,georg,wez,edink,helly,hholzgra,imajes,gschlossnagle,moriyoshi,dmitry,jon,pollita,tony2001,johannes,bjori,davidw,nicholsr,wharmby,felipe,robinf,scottmac,nlopess,mattwil,colder,lbarnaud,pajoye,cseiler,dsp,shire|Zend,ZendEngine2,TSRM
@@ -360,7 +360,7 @@
 avail|pajoye,guilhermeblanco,auroraeosrose,rrichards,kalle|php-windows-web
 
 # php-benchmarks karma
-avail|olafurw,nlopess,pbiggar|php-benchmarks
+avail|olafurw,nlopess,pbiggar,hjalle|php-benchmarks
 
 # phpruntests karma
 avail|zoe,spriebsch|phpruntests



-- 
PHP CVS Mailing List (http://www.php.net/)
To unsubscribe, visit: http://www.php.net/unsub.php



[PHP-CVS] cvs: php-src(PHP_5_3) /main main.c

2009-04-30 Thread Pierre-Alain Joye
pajoye  Thu Apr 30 09:11:01 2009 UTC

  Modified files:  (Branch: PHP_5_3)
/php-src/main   main.c 
  Log:
  - fix build (Marcus, fix re2c please)
  
http://cvs.php.net/viewvc.cgi/php-src/main/main.c?r1=1.640.2.23.2.57.2.48r2=1.640.2.23.2.57.2.49diff_format=u
Index: php-src/main/main.c
diff -u php-src/main/main.c:1.640.2.23.2.57.2.48 
php-src/main/main.c:1.640.2.23.2.57.2.49
--- php-src/main/main.c:1.640.2.23.2.57.2.48Tue Apr 28 07:13:30 2009
+++ php-src/main/main.c Thu Apr 30 09:11:00 2009
@@ -18,7 +18,7 @@
+--+
 */
 
-/* $Id: main.c,v 1.640.2.23.2.57.2.48 2009/04/28 07:13:30 dmitry Exp $ */
+/* $Id: main.c,v 1.640.2.23.2.57.2.49 2009/04/30 09:11:00 pajoye Exp $ */
 
 /* {{{ includes
  */
@@ -96,6 +96,9 @@
 #  define PAGE_SIZE 4096
 # endif
 #endif
+#ifdef PHP_WIN32
+# define PAGE_SIZE 4096
+#endif
 /* }}} */
 
 PHPAPI int (*php_register_internal_extensions_func)(TSRMLS_D) = 
php_register_internal_extensions;



-- 
PHP CVS Mailing List (http://www.php.net/)
To unsubscribe, visit: http://www.php.net/unsub.php



[PHP-CVS] cvs: php-src(PHP_5_2) /ext/soap/tests/bugs bug41477.phpt

2009-04-30 Thread Jani Taskinen
janiThu Apr 30 09:50:49 2009 UTC

  Modified files:  (Branch: PHP_5_2)
/php-src/ext/soap/tests/bugsbug41477.phpt 
  Log:
  - It is possible to disable reflection extension in PHP_5_2
  
http://cvs.php.net/viewvc.cgi/php-src/ext/soap/tests/bugs/bug41477.phpt?r1=1.1.2.1r2=1.1.2.2diff_format=u
Index: php-src/ext/soap/tests/bugs/bug41477.phpt
diff -u php-src/ext/soap/tests/bugs/bug41477.phpt:1.1.2.1 
php-src/ext/soap/tests/bugs/bug41477.phpt:1.1.2.2
--- php-src/ext/soap/tests/bugs/bug41477.phpt:1.1.2.1   Sun May 27 17:46:46 2007
+++ php-src/ext/soap/tests/bugs/bug41477.phpt   Thu Apr 30 09:50:48 2009
@@ -1,7 +1,10 @@
 --TEST--
 Bug #41477 (no arginfo about SoapClient::__soapCall())
 --SKIPIF--
-?php require_once('skipif.inc'); ?
+?php
+if (!extension_loaded(reflection)) die(skip);
+require_once('skipif.inc');
+?
 --FILE--
 ?php
 $objRfClass = new ReflectionClass('SoapClient');
@@ -9,7 +12,7 @@
 $arrParams = $objRfMethod-getParameters();
 foreach($arrParams as $objRfParam)
 {
-var_dump($objRfParam-getName());
+   var_dump($objRfParam-getName());
 }
 ?
 --EXPECT--



-- 
PHP CVS Mailing List (http://www.php.net/)
To unsubscribe, visit: http://www.php.net/unsub.php



[PHP-CVS] cvs: php-src /ext/curl/tests bug45161.phpt bug46711.phpt

2009-04-30 Thread Jani Taskinen
janiThu Apr 30 10:41:09 2009 UTC

  Modified files:  
/php-src/ext/curl/tests bug46711.phpt bug45161.phpt 
  Log:
  - Add missing test
  
http://cvs.php.net/viewvc.cgi/php-src/ext/curl/tests/bug46711.phpt?r1=1.1r2=1.2diff_format=u
Index: php-src/ext/curl/tests/bug46711.phpt
diff -u /dev/null php-src/ext/curl/tests/bug46711.phpt:1.2
--- /dev/null   Thu Apr 30 10:41:09 2009
+++ php-src/ext/curl/tests/bug46711.phptThu Apr 30 10:41:09 2009
@@ -0,0 +1,27 @@
+--TEST--
+Bug #46711 (lost memory when foreach is used for values passed to 
curl_setopt())
+--FILE--
+?php
+$ch = curl_init();
+
+$opt = array(
+   CURLOPT_AUTOREFERER  = TRUE,
+   CURLOPT_BINARYTRANSFER = TRUE
+);
+
+curl_setopt( $ch, CURLOPT_AUTOREFERER  , TRUE );
+
+foreach( $opt as $option = $value ) {
+   curl_setopt( $ch, $option, $value );
+}
+
+var_dump($opt); // with this bug, $opt[58] becomes NULL
+
+?
+--EXPECT--
+array(2) {
+  [58]=
+  bool(true)
+  [19914]=
+  bool(true)
+}
http://cvs.php.net/viewvc.cgi/php-src/ext/curl/tests/bug45161.phpt?r1=1.1r2=1.2diff_format=u
Index: php-src/ext/curl/tests/bug45161.phpt
diff -u php-src/ext/curl/tests/bug45161.phpt:1.1 
php-src/ext/curl/tests/bug45161.phpt:1.2
--- php-src/ext/curl/tests/bug45161.phpt:1.1Wed Dec 17 13:59:21 2008
+++ php-src/ext/curl/tests/bug45161.phptThu Apr 30 10:41:09 2009
@@ -1,5 +1,7 @@
 --TEST--
 Bug #45161 (Reusing a curl handle leaks memory)
+--SKIPIF--
+?php $curl_version = curl_version(); if ($curl_version['version_number']  
0x071100) die(skip: test works only with curl = 7.17.0); ?
 --FILE--
 ?php
 



-- 
PHP CVS Mailing List (http://www.php.net/)
To unsubscribe, visit: http://www.php.net/unsub.php



[PHP-CVS] cvs: php-src(PHP_5_2) /ext/curl/tests bug45161.phpt bug46711.phpt

2009-04-30 Thread Jani Taskinen
janiThu Apr 30 10:41:32 2009 UTC

  Added files: (Branch: PHP_5_2)
/php-src/ext/curl/tests bug46711.phpt 

  Modified files:  
/php-src/ext/curl/tests bug45161.phpt 
  Log:
  - Fix test + add missing test
  
http://cvs.php.net/viewvc.cgi/php-src/ext/curl/tests/bug45161.phpt?r1=1.1.4.2r2=1.1.4.3diff_format=u
Index: php-src/ext/curl/tests/bug45161.phpt
diff -u php-src/ext/curl/tests/bug45161.phpt:1.1.4.2 
php-src/ext/curl/tests/bug45161.phpt:1.1.4.3
--- php-src/ext/curl/tests/bug45161.phpt:1.1.4.2Wed Dec 17 14:05:52 2008
+++ php-src/ext/curl/tests/bug45161.phptThu Apr 30 10:41:32 2009
@@ -1,5 +1,7 @@
 --TEST--
 Bug #45161 (Reusing a curl handle leaks memory)
+--SKIPIF--
+?php $curl_version = curl_version(); if ($curl_version['version_number']  
0x071100) die(skip: test works only with curl = 7.17.0); ?
 --FILE--
 ?php
 

http://cvs.php.net/viewvc.cgi/php-src/ext/curl/tests/bug46711.phpt?view=markuprev=1.1
Index: php-src/ext/curl/tests/bug46711.phpt
+++ php-src/ext/curl/tests/bug46711.phpt



-- 
PHP CVS Mailing List (http://www.php.net/)
To unsubscribe, visit: http://www.php.net/unsub.php



[PHP-CVS] cvs: php-src(PHP_5_3) /ext/curl/tests bug45161.phpt bug46711.phpt

2009-04-30 Thread Jani Taskinen
janiThu Apr 30 10:41:54 2009 UTC

  Modified files:  (Branch: PHP_5_3)
/php-src/ext/curl/tests bug45161.phpt bug46711.phpt 
  Log:
  MFH
  
http://cvs.php.net/viewvc.cgi/php-src/ext/curl/tests/bug45161.phpt?r1=1.1.2.2r2=1.1.2.3diff_format=u
Index: php-src/ext/curl/tests/bug45161.phpt
diff -u php-src/ext/curl/tests/bug45161.phpt:1.1.2.2 
php-src/ext/curl/tests/bug45161.phpt:1.1.2.3
--- php-src/ext/curl/tests/bug45161.phpt:1.1.2.2Wed Dec 17 13:59:47 2008
+++ php-src/ext/curl/tests/bug45161.phptThu Apr 30 10:41:54 2009
@@ -1,5 +1,7 @@
 --TEST--
 Bug #45161 (Reusing a curl handle leaks memory)
+--SKIPIF--
+?php $curl_version = curl_version(); if ($curl_version['version_number']  
0x071100) die(skip: test works only with curl = 7.17.0); ?
 --FILE--
 ?php
 
http://cvs.php.net/viewvc.cgi/php-src/ext/curl/tests/bug46711.phpt?r1=1.1.2.1r2=1.1.2.2diff_format=u
Index: php-src/ext/curl/tests/bug46711.phpt
diff -u php-src/ext/curl/tests/bug46711.phpt:1.1.2.1 
php-src/ext/curl/tests/bug46711.phpt:1.1.2.2
--- php-src/ext/curl/tests/bug46711.phpt:1.1.2.1Sun Nov 30 17:30:50 2008
+++ php-src/ext/curl/tests/bug46711.phptThu Apr 30 10:41:54 2009
@@ -1,9 +1,5 @@
 --TEST--
-#46711 (lost memory when foreach is used for values passed to curl_setopt())
---SKIP--
-?php
-if (!extension_loaded('curl')) die('skip need curl to work');
-?
+Bug #46711 (lost memory when foreach is used for values passed to 
curl_setopt())
 --FILE--
 ?php
 $ch = curl_init();



-- 
PHP CVS Mailing List (http://www.php.net/)
To unsubscribe, visit: http://www.php.net/unsub.php



[PHP-CVS] cvs: php-src(PHP_5_2) /tests/classes inheritance_007.phpt

2009-04-30 Thread Jani Taskinen
janiThu Apr 30 11:14:09 2009 UTC

  Modified files:  (Branch: PHP_5_2)
/php-src/tests/classes  inheritance_007.phpt 
  Log:
  - Reflection can be disabled in PHP_5_2
  
http://cvs.php.net/viewvc.cgi/php-src/tests/classes/inheritance_007.phpt?r1=1.1.2.4r2=1.1.2.5diff_format=u
Index: php-src/tests/classes/inheritance_007.phpt
diff -u php-src/tests/classes/inheritance_007.phpt:1.1.2.4 
php-src/tests/classes/inheritance_007.phpt:1.1.2.5
--- php-src/tests/classes/inheritance_007.phpt:1.1.2.4  Tue Apr 28 23:46:39 2009
+++ php-src/tests/classes/inheritance_007.phpt  Thu Apr 30 11:14:09 2009
@@ -1,5 +1,7 @@
 --TEST--
 Ensure inherited old-style constructor doesn't block other methods.
+--SKIPIF--
+?php extension_loaded('reflection') or die('skip'); ?
 --FILE--
 ?php
 class A {



-- 
PHP CVS Mailing List (http://www.php.net/)
To unsubscribe, visit: http://www.php.net/unsub.php



[PHP-CVS] cvs: php-src /main main.c

2009-04-30 Thread Pierre-Alain Joye
pajoye  Thu Apr 30 09:12:26 2009 UTC

  Modified files:  
/php-src/main   main.c 
  Log:
  - fix build (Marcus, fix re2c please)
  
http://cvs.php.net/viewvc.cgi/php-src/main/main.c?r1=1.796r2=1.797diff_format=u
Index: php-src/main/main.c
diff -u php-src/main/main.c:1.796 php-src/main/main.c:1.797
--- php-src/main/main.c:1.796   Tue Apr 28 07:13:43 2009
+++ php-src/main/main.c Thu Apr 30 09:12:26 2009
@@ -18,7 +18,7 @@
+--+
 */
 
-/* $Id: main.c,v 1.796 2009/04/28 07:13:43 dmitry Exp $ */
+/* $Id: main.c,v 1.797 2009/04/30 09:12:26 pajoye Exp $ */
 
 /* {{{ includes
  */
@@ -96,6 +96,9 @@
 #  define PAGE_SIZE 4096
 # endif
 #endif
+#ifdef PHP_WIN32
+# define PAGE_SIZE 4096
+#endif
 /* }}} */
 
 PHPAPI int (*php_register_internal_extensions_func)(TSRMLS_D) = 
php_register_internal_extensions;



-- 
PHP CVS Mailing List (http://www.php.net/)
To unsubscribe, visit: http://www.php.net/unsub.php



[PHP-CVS] cvs: php-src(PHP_5_2) /ext/date/tests DateTimeZone_verify.phpt DateTime_verify.phpt

2009-04-30 Thread Jani Taskinen
janiThu Apr 30 09:56:15 2009 UTC

  Modified files:  (Branch: PHP_5_2)
/php-src/ext/date/tests DateTimeZone_verify.phpt 
DateTime_verify.phpt 
  Log:
  - It is possible to disable reflection extension in PHP_5_2
  
http://cvs.php.net/viewvc.cgi/php-src/ext/date/tests/DateTimeZone_verify.phpt?r1=1.1.2.1r2=1.1.2.2diff_format=u
Index: php-src/ext/date/tests/DateTimeZone_verify.phpt
diff -u php-src/ext/date/tests/DateTimeZone_verify.phpt:1.1.2.1 
php-src/ext/date/tests/DateTimeZone_verify.phpt:1.1.2.2
--- php-src/ext/date/tests/DateTimeZone_verify.phpt:1.1.2.1 Wed Mar 18 
11:12:59 2009
+++ php-src/ext/date/tests/DateTimeZone_verify.phpt Thu Apr 30 09:56:15 2009
@@ -1,5 +1,7 @@
 --TEST--
 Test DateTimeZone class registration
+--SKIPIF--
+?php if (!extension_loaded(reflection)) die(skip); ?
 --FILE--
 ?php
 
http://cvs.php.net/viewvc.cgi/php-src/ext/date/tests/DateTime_verify.phpt?r1=1.1.2.1r2=1.1.2.2diff_format=u
Index: php-src/ext/date/tests/DateTime_verify.phpt
diff -u php-src/ext/date/tests/DateTime_verify.phpt:1.1.2.1 
php-src/ext/date/tests/DateTime_verify.phpt:1.1.2.2
--- php-src/ext/date/tests/DateTime_verify.phpt:1.1.2.1 Wed Mar 18 11:32:53 2009
+++ php-src/ext/date/tests/DateTime_verify.phpt Thu Apr 30 09:56:15 2009
@@ -1,5 +1,7 @@
 --TEST--
 Test DateTime class registration
+--SKIPIF--
+?php if (!extension_loaded(reflection)) die(skip); ?
 --FILE--
 ?php
 



-- 
PHP CVS Mailing List (http://www.php.net/)
To unsubscribe, visit: http://www.php.net/unsub.php



[PHP-CVS] cvs: php-src /ext/pdo_pgsql config.m4 config.w32 pgsql_driver.c pgsql_statement.c php_pdo_pgsql_int.h

2009-04-30 Thread Matteo Beccati
mbeccatiThu Apr 30 12:35:36 2009 UTC

  Modified files:  
/php-src/ext/pdo_pgsql  config.m4 config.w32 pgsql_driver.c 
pgsql_statement.c php_pdo_pgsql_int.h 
  Log:
  - Changed PDO_PGSQL configure script to require libpq 7.4
  - Cleaned up usage of HAVE_PQ* defines
  - Fixed compiler warnings
  - Removed custom implementation of PQunescapeByte
  # Rationale:
  # - PDO_PGSQL couldn't even compile when using libpq 7.3
  # - PostgreSQL 7.3 is unsupported since a long time
  # - Got consensus from pgsql devs on freenode
  
  http://cvs.php.net/viewvc.cgi/php-src/ext/pdo_pgsql/config.m4?r1=1.21r2=1.22diff_format=u
Index: php-src/ext/pdo_pgsql/config.m4
diff -u php-src/ext/pdo_pgsql/config.m4:1.21 
php-src/ext/pdo_pgsql/config.m4:1.22
--- php-src/ext/pdo_pgsql/config.m4:1.21Sat Mar 28 02:34:02 2009
+++ php-src/ext/pdo_pgsql/config.m4 Thu Apr 30 12:35:36 2009
@@ -1,4 +1,4 @@
-dnl $Id: config.m4,v 1.21 2009/03/28 02:34:02 mbeccati Exp $
+dnl $Id: config.m4,v 1.22 2009/04/30 12:35:36 mbeccati Exp $
 dnl config.m4 for extension pdo_pgsql
 dnl vim:et:sw=2:ts=2:
 
@@ -82,23 +82,18 @@
 
   old_LIBS=$LIBS
   old_LDFLAGS=$LDFLAGS
-  LDFLAGS=$LDFLAGS -L$PGSQL_LIBDIR
-  AC_CHECK_LIB(pq, PQescapeString,AC_DEFINE(HAVE_PQESCAPE,1,[PostgreSQL 7.2.0 
or later]))
+  LDFLAGS=-L$PGSQL_LIBDIR $LDFLAGS
+  AC_CHECK_LIB(pq, 
PQparameterStatus,AC_DEFINE(HAVE_PQPARAMETERSTATUS,1,[PostgreSQL 7.4 or 
later]), [
+echo Unable to build the PDO PostgreSQL driver: libpq 7.4+ is required
+exit 1
+  ])
+
+  AC_CHECK_LIB(pq, PQprepare,AC_DEFINE(HAVE_PQPREPARE,1,[PostgreSQL 8.0 or 
later]))
   AC_CHECK_LIB(pq, PQescapeStringConn, 
AC_DEFINE(HAVE_PQESCAPE_CONN,1,[PostgreSQL 8.1.4 or later]))
   AC_CHECK_LIB(pq, PQescapeByteaConn, 
AC_DEFINE(HAVE_PQESCAPE_BYTEA_CONN,1,[PostgreSQL 8.1.4 or later]))
-  AC_CHECK_LIB(pq, 
PQsetnonblocking,AC_DEFINE(HAVE_PQSETNONBLOCKING,1,[PostgreSQL 7.0.x or later]))
-  AC_CHECK_LIB(pq, PQcmdTuples,AC_DEFINE(HAVE_PQCMDTUPLES,1,[Broken libpq 
under windows]))
-  AC_CHECK_LIB(pq, PQoidValue,AC_DEFINE(HAVE_PQOIDVALUE,1,[Older PostgreSQL]))
-  AC_CHECK_LIB(pq, 
PQclientEncoding,AC_DEFINE(HAVE_PQCLIENTENCODING,1,[PostgreSQL 7.0.x or later]))
-  AC_CHECK_LIB(pq, 
PQparameterStatus,AC_DEFINE(HAVE_PQPARAMETERSTATUS,1,[PostgreSQL 7.4 or later]))
-  AC_CHECK_LIB(pq, 
PQprotocolVersion,AC_DEFINE(HAVE_PQPROTOCOLVERSION,1,[PostgreSQL 7.4 or later]))
-  AC_CHECK_LIB(pq, 
PQtransactionStatus,AC_DEFINE(HAVE_PGTRANSACTIONSTATUS,1,[PostgreSQL 7.4 or 
later]))
-  AC_CHECK_LIB(pq, 
PQunescapeBytea,AC_DEFINE(HAVE_PQUNESCAPEBYTEA,1,[PostgreSQL 7.4 or later]))
-  AC_CHECK_LIB(pq, PQExecParams,AC_DEFINE(HAVE_PQEXECPARAMS,1,[PostgreSQL 7.4 
or later]))
-  AC_CHECK_LIB(pq, 
PQresultErrorField,AC_DEFINE(HAVE_PQRESULTERRORFIELD,1,[PostgreSQL 7.4 or 
later]))
+
   AC_CHECK_LIB(pq, 
pg_encoding_to_char,AC_DEFINE(HAVE_PGSQL_WITH_MULTIBYTE_SUPPORT,1,[Whether 
libpq is compiled with --enable-multibyte]))
   
-  AC_CHECK_LIB(pq, PQprepare,AC_DEFINE(HAVE_PQPREPARE,1,[prepared statements]))
 
   LIBS=$old_LIBS
   LDFLAGS=$old_LDFLAGS
http://cvs.php.net/viewvc.cgi/php-src/ext/pdo_pgsql/config.w32?r1=1.10r2=1.11diff_format=u
Index: php-src/ext/pdo_pgsql/config.w32
diff -u php-src/ext/pdo_pgsql/config.w32:1.10 
php-src/ext/pdo_pgsql/config.w32:1.11
--- php-src/ext/pdo_pgsql/config.w32:1.10   Wed Apr  1 16:16:20 2009
+++ php-src/ext/pdo_pgsql/config.w32Thu Apr 30 12:35:36 2009
@@ -1,4 +1,4 @@
-// $Id: config.w32,v 1.10 2009/04/01 16:16:20 pajoye Exp $
+// $Id: config.w32,v 1.11 2009/04/30 12:35:36 mbeccati Exp $
 // vim:ft=javascript
 
 ARG_WITH(pdo-pgsql, PostgreSQL support for PDO, no);
@@ -12,8 +12,11 @@
ADD_FLAG('CFLAGS_PDO_PGSQL', /D HAVE_PG_CONFIG_H);
}
 
-   AC_DEFINE('HAVE_PQPREPARE', 1, 'Have PqPrepare');
-   AC_DEFINE('HAVE_PDO_PGSQL', 1, 'Have PostgreSQL library');
+   AC_DEFINE('HAVE_PDO_PGSQL', 1, 'Have PostgreSQL 
library');
+   AC_DEFINE('HAVE_PQESCAPE_BYTEA_CONN',   1, 'Have 
PQescapeByteaConn');
+   AC_DEFINE('HAVE_PQESCAPE_CONN', 1, 'Have PQescapeConn');
+   AC_DEFINE('HAVE_PQEXECPARAMS',  1, 'Have PQexecParams');
+   AC_DEFINE('HAVE_PQPREPARE', 1, 'Have PQprepare');
ADD_FLAG('CFLAGS_PDO_PGSQL', /D HAVE_PQPARAMETERSTATUS=1 /D 
HAVE_PQPROTOCOLVERSION=1 /D HAVE_PGTRANSACTIONSTATUS=1 /D 
HAVE_PQUNESCAPEBYTEA=1 /D HAVE_PQRESULTERRORFIELD=1 /D HAVE_PQESCAPE_CONN=1 /D 
HAVE_PQESCAPE_BYTEA_CONN=1);
ADD_EXTENSION_DEP('pdo_pgsql', 'pdo');
} else {
http://cvs.php.net/viewvc.cgi/php-src/ext/pdo_pgsql/pgsql_driver.c?r1=1.73r2=1.74diff_format=u
Index: php-src/ext/pdo_pgsql/pgsql_driver.c
diff -u php-src/ext/pdo_pgsql/pgsql_driver.c:1.73 
php-src/ext/pdo_pgsql/pgsql_driver.c:1.74
--- php-src/ext/pdo_pgsql/pgsql_driver.c:1.73   Wed Apr  1 16:14:50 2009
+++ 

[PHP-CVS] cvs: php-src(PHP_5_3) /ext/pdo_pgsql config.m4 config.w32 pgsql_driver.c pgsql_statement.c php_pdo_pgsql_int.h

2009-04-30 Thread Matteo Beccati
mbeccatiThu Apr 30 12:38:43 2009 UTC

  Modified files:  (Branch: PHP_5_3)
/php-src/ext/pdo_pgsql  config.m4 config.w32 pgsql_driver.c 
pgsql_statement.c php_pdo_pgsql_int.h 
  Log:
  MFH:
  - Changed PDO_PGSQL configure script to require libpq 7.4
  - Cleaned up usage of HAVE_PQ* defines
  - Fixed compiler warnings
  - Removed custom implementation of PQunescapeByte
  # Rationale:
  # - PDO_PGSQL couldn't even compile when using libpq 7.3
  # - PostgreSQL 7.3 is unsupported since a long time
  # - Got consensus from pgsql devs on freenode
  
  http://cvs.php.net/viewvc.cgi/php-src/ext/pdo_pgsql/config.m4?r1=1.13.4.6.2.1r2=1.13.4.6.2.2diff_format=u
Index: php-src/ext/pdo_pgsql/config.m4
diff -u php-src/ext/pdo_pgsql/config.m4:1.13.4.6.2.1 
php-src/ext/pdo_pgsql/config.m4:1.13.4.6.2.2
--- php-src/ext/pdo_pgsql/config.m4:1.13.4.6.2.1Fri Jul 25 13:46:24 2008
+++ php-src/ext/pdo_pgsql/config.m4 Thu Apr 30 12:38:43 2009
@@ -1,4 +1,4 @@
-dnl $Id: config.m4,v 1.13.4.6.2.1 2008/07/25 13:46:24 jani Exp $
+dnl $Id: config.m4,v 1.13.4.6.2.2 2009/04/30 12:38:43 mbeccati Exp $
 dnl config.m4 for extension pdo_pgsql
 dnl vim:et:sw=2:ts=2:
 
@@ -82,23 +82,18 @@
 
   old_LIBS=$LIBS
   old_LDFLAGS=$LDFLAGS
-  LDFLAGS=$LDFLAGS -L$PGSQL_LIBDIR
-  AC_CHECK_LIB(pq, PQescapeString,AC_DEFINE(HAVE_PQESCAPE,1,[PostgreSQL 7.2.0 
or later]))
+  LDFLAGS=-L$PGSQL_LIBDIR $LDFLAGS
+  AC_CHECK_LIB(pq, 
PQparameterStatus,AC_DEFINE(HAVE_PQPARAMETERSTATUS,1,[PostgreSQL 7.4 or 
later]), [
+echo Unable to build the PDO PostgreSQL driver: libpq 7.4+ is required
+exit 1
+  ])
+
+  AC_CHECK_LIB(pq, PQprepare,AC_DEFINE(HAVE_PQPREPARE,1,[PostgreSQL 8.0 or 
later]))
   AC_CHECK_LIB(pq, PQescapeStringConn, 
AC_DEFINE(HAVE_PQESCAPE_CONN,1,[PostgreSQL 8.1.4 or later]))
   AC_CHECK_LIB(pq, PQescapeByteaConn, 
AC_DEFINE(HAVE_PQESCAPE_BYTEA_CONN,1,[PostgreSQL 8.1.4 or later]))
-  AC_CHECK_LIB(pq, 
PQsetnonblocking,AC_DEFINE(HAVE_PQSETNONBLOCKING,1,[PostgreSQL 7.0.x or later]))
-  AC_CHECK_LIB(pq, PQcmdTuples,AC_DEFINE(HAVE_PQCMDTUPLES,1,[Broken libpq 
under windows]))
-  AC_CHECK_LIB(pq, PQoidValue,AC_DEFINE(HAVE_PQOIDVALUE,1,[Older PostgreSQL]))
-  AC_CHECK_LIB(pq, 
PQclientEncoding,AC_DEFINE(HAVE_PQCLIENTENCODING,1,[PostgreSQL 7.0.x or later]))
-  AC_CHECK_LIB(pq, 
PQparameterStatus,AC_DEFINE(HAVE_PQPARAMETERSTATUS,1,[PostgreSQL 7.4 or later]))
-  AC_CHECK_LIB(pq, 
PQprotocolVersion,AC_DEFINE(HAVE_PQPROTOCOLVERSION,1,[PostgreSQL 7.4 or later]))
-  AC_CHECK_LIB(pq, 
PQtransactionStatus,AC_DEFINE(HAVE_PGTRANSACTIONSTATUS,1,[PostgreSQL 7.4 or 
later]))
-  AC_CHECK_LIB(pq, 
PQunescapeBytea,AC_DEFINE(HAVE_PQUNESCAPEBYTEA,1,[PostgreSQL 7.4 or later]))
-  AC_CHECK_LIB(pq, PQExecParams,AC_DEFINE(HAVE_PQEXECPARAMS,1,[PostgreSQL 7.4 
or later]))
-  AC_CHECK_LIB(pq, 
PQresultErrorField,AC_DEFINE(HAVE_PQRESULTERRORFIELD,1,[PostgreSQL 7.4 or 
later]))
+
   AC_CHECK_LIB(pq, 
pg_encoding_to_char,AC_DEFINE(HAVE_PGSQL_WITH_MULTIBYTE_SUPPORT,1,[Whether 
libpq is compiled with --enable-multibyte]))
   
-  AC_CHECK_LIB(pq, PQprepare,AC_DEFINE(HAVE_PQPREPARE,1,[prepared statements]))
 
   LIBS=$old_LIBS
   LDFLAGS=$old_LDFLAGS
http://cvs.php.net/viewvc.cgi/php-src/ext/pdo_pgsql/config.w32?r1=1.4.2.1.2.3.2.3r2=1.4.2.1.2.3.2.4diff_format=u
Index: php-src/ext/pdo_pgsql/config.w32
diff -u php-src/ext/pdo_pgsql/config.w32:1.4.2.1.2.3.2.3 
php-src/ext/pdo_pgsql/config.w32:1.4.2.1.2.3.2.4
--- php-src/ext/pdo_pgsql/config.w32:1.4.2.1.2.3.2.3Wed Apr  1 16:16:49 2009
+++ php-src/ext/pdo_pgsql/config.w32Thu Apr 30 12:38:43 2009
@@ -1,4 +1,4 @@
-// $Id: config.w32,v 1.4.2.1.2.3.2.3 2009/04/01 16:16:49 pajoye Exp $
+// $Id: config.w32,v 1.4.2.1.2.3.2.4 2009/04/30 12:38:43 mbeccati Exp $
 // vim:ft=javascript
 
 ARG_WITH(pdo-pgsql, PostgreSQL support for PDO, no);
@@ -12,8 +12,11 @@
ADD_FLAG('CFLAGS_PDO_PGSQL', /D HAVE_PG_CONFIG_H);
}
 
-   AC_DEFINE('HAVE_PQPREPARE', 1, 'Have PqPrepare');
-   AC_DEFINE('HAVE_PDO_PGSQL', 1, 'Have PostgreSQL library');
+   AC_DEFINE('HAVE_PDO_PGSQL', 1, 'Have PostgreSQL 
library');
+   AC_DEFINE('HAVE_PQESCAPE_BYTEA_CONN',   1, 'Have 
PQescapeByteaConn');
+   AC_DEFINE('HAVE_PQESCAPE_CONN', 1, 'Have PQescapeConn');
+   AC_DEFINE('HAVE_PQEXECPARAMS',  1, 'Have PQexecParams');
+   AC_DEFINE('HAVE_PQPREPARE', 1, 'Have PQprepare');
ADD_FLAG('CFLAGS_PDO_PGSQL', /D HAVE_PQPARAMETERSTATUS=1 /D 
HAVE_PQPROTOCOLVERSION=1 /D HAVE_PGTRANSACTIONSTATUS=1 /D 
HAVE_PQUNESCAPEBYTEA=1 /D HAVE_PQRESULTERRORFIELD=1 /D HAVE_PQESCAPE_CONN=1 /D 
HAVE_PQESCAPE_BYTEA_CONN=1);
ADD_EXTENSION_DEP('pdo_pgsql', 'pdo');
} else {
http://cvs.php.net/viewvc.cgi/php-src/ext/pdo_pgsql/pgsql_driver.c?r1=1.53.2.14.2.9.2.6r2=1.53.2.14.2.9.2.7diff_format=u
Index: 

[PHP-CVS] cvs: php-src /ext/pdo_pgsql config.w32 pgsql_driver.c

2009-04-30 Thread Matteo Beccati
mbeccatiThu Apr 30 12:55:43 2009 UTC

  Modified files:  
/php-src/ext/pdo_pgsql  config.w32 pgsql_driver.c 
  Log:
  - Removed HAVE_PQEXECPARAMS which was left out during the previous commit
  
  
http://cvs.php.net/viewvc.cgi/php-src/ext/pdo_pgsql/config.w32?r1=1.11r2=1.12diff_format=u
Index: php-src/ext/pdo_pgsql/config.w32
diff -u php-src/ext/pdo_pgsql/config.w32:1.11 
php-src/ext/pdo_pgsql/config.w32:1.12
--- php-src/ext/pdo_pgsql/config.w32:1.11   Thu Apr 30 12:35:36 2009
+++ php-src/ext/pdo_pgsql/config.w32Thu Apr 30 12:55:43 2009
@@ -1,4 +1,4 @@
-// $Id: config.w32,v 1.11 2009/04/30 12:35:36 mbeccati Exp $
+// $Id: config.w32,v 1.12 2009/04/30 12:55:43 mbeccati Exp $
 // vim:ft=javascript
 
 ARG_WITH(pdo-pgsql, PostgreSQL support for PDO, no);
@@ -15,7 +15,6 @@
AC_DEFINE('HAVE_PDO_PGSQL', 1, 'Have PostgreSQL 
library');
AC_DEFINE('HAVE_PQESCAPE_BYTEA_CONN',   1, 'Have 
PQescapeByteaConn');
AC_DEFINE('HAVE_PQESCAPE_CONN', 1, 'Have PQescapeConn');
-   AC_DEFINE('HAVE_PQEXECPARAMS',  1, 'Have PQexecParams');
AC_DEFINE('HAVE_PQPREPARE', 1, 'Have PQprepare');
ADD_FLAG('CFLAGS_PDO_PGSQL', /D HAVE_PQPARAMETERSTATUS=1 /D 
HAVE_PQPROTOCOLVERSION=1 /D HAVE_PGTRANSACTIONSTATUS=1 /D 
HAVE_PQUNESCAPEBYTEA=1 /D HAVE_PQRESULTERRORFIELD=1 /D HAVE_PQESCAPE_CONN=1 /D 
HAVE_PQESCAPE_BYTEA_CONN=1);
ADD_EXTENSION_DEP('pdo_pgsql', 'pdo');
http://cvs.php.net/viewvc.cgi/php-src/ext/pdo_pgsql/pgsql_driver.c?r1=1.74r2=1.75diff_format=u
Index: php-src/ext/pdo_pgsql/pgsql_driver.c
diff -u php-src/ext/pdo_pgsql/pgsql_driver.c:1.74 
php-src/ext/pdo_pgsql/pgsql_driver.c:1.75
--- php-src/ext/pdo_pgsql/pgsql_driver.c:1.74   Thu Apr 30 12:35:36 2009
+++ php-src/ext/pdo_pgsql/pgsql_driver.cThu Apr 30 12:55:43 2009
@@ -18,7 +18,7 @@
   +--+
 */
 
-/* $Id: pgsql_driver.c,v 1.74 2009/04/30 12:35:36 mbeccati Exp $ */
+/* $Id: pgsql_driver.c,v 1.75 2009/04/30 12:55:43 mbeccati Exp $ */
 
 #ifdef HAVE_CONFIG_H
 #include config.h
@@ -356,25 +356,9 @@
} else {
PGresult *res;
ExecStatusType status;
-#ifdef HAVE_PQEXECPARAMS
const char *q[1];
q[0] = name;
res = PQexecParams(H-server, SELECT CURRVAL($1), 1, NULL, q, 
NULL, NULL, 0);
-#else
-   char *name_escaped, *q;
-   size_t l = strlen(name);
-
-   name_escaped = safe_emalloc(l, 2, 1);
-#ifndef HAVE_PQESCAPE_CONN
-   PQescapeString(name_escaped, name, l);
-#else
-   PQescapeStringConn(H-server, name_escaped, name, l, NULL);
-#endif
-   spprintf(q, 0, SELECT CURRVAL('%s'), name_escaped);
-   res = PQexec(H-server, q);
-   efree(name_escaped); 
-   efree(q);
-#endif
status = PQresultStatus(res);
 
if (res  (status == PGRES_TUPLES_OK)) {



-- 
PHP CVS Mailing List (http://www.php.net/)
To unsubscribe, visit: http://www.php.net/unsub.php



[PHP-CVS] cvs: php-src(PHP_5_3) /ext/pdo_pgsql config.w32 pgsql_driver.c

2009-04-30 Thread Matteo Beccati
mbeccatiThu Apr 30 12:56:00 2009 UTC

  Modified files:  (Branch: PHP_5_3)
/php-src/ext/pdo_pgsql  config.w32 pgsql_driver.c 
  Log:
  MFH:
  - Removed HAVE_PQEXECPARAMS which was left out during the previous commit
  
  
http://cvs.php.net/viewvc.cgi/php-src/ext/pdo_pgsql/config.w32?r1=1.4.2.1.2.3.2.4r2=1.4.2.1.2.3.2.5diff_format=u
Index: php-src/ext/pdo_pgsql/config.w32
diff -u php-src/ext/pdo_pgsql/config.w32:1.4.2.1.2.3.2.4 
php-src/ext/pdo_pgsql/config.w32:1.4.2.1.2.3.2.5
--- php-src/ext/pdo_pgsql/config.w32:1.4.2.1.2.3.2.4Thu Apr 30 12:38:43 2009
+++ php-src/ext/pdo_pgsql/config.w32Thu Apr 30 12:56:00 2009
@@ -1,4 +1,4 @@
-// $Id: config.w32,v 1.4.2.1.2.3.2.4 2009/04/30 12:38:43 mbeccati Exp $
+// $Id: config.w32,v 1.4.2.1.2.3.2.5 2009/04/30 12:56:00 mbeccati Exp $
 // vim:ft=javascript
 
 ARG_WITH(pdo-pgsql, PostgreSQL support for PDO, no);
@@ -15,7 +15,6 @@
AC_DEFINE('HAVE_PDO_PGSQL', 1, 'Have PostgreSQL 
library');
AC_DEFINE('HAVE_PQESCAPE_BYTEA_CONN',   1, 'Have 
PQescapeByteaConn');
AC_DEFINE('HAVE_PQESCAPE_CONN', 1, 'Have PQescapeConn');
-   AC_DEFINE('HAVE_PQEXECPARAMS',  1, 'Have PQexecParams');
AC_DEFINE('HAVE_PQPREPARE', 1, 'Have PQprepare');
ADD_FLAG('CFLAGS_PDO_PGSQL', /D HAVE_PQPARAMETERSTATUS=1 /D 
HAVE_PQPROTOCOLVERSION=1 /D HAVE_PGTRANSACTIONSTATUS=1 /D 
HAVE_PQUNESCAPEBYTEA=1 /D HAVE_PQRESULTERRORFIELD=1 /D HAVE_PQESCAPE_CONN=1 /D 
HAVE_PQESCAPE_BYTEA_CONN=1);
ADD_EXTENSION_DEP('pdo_pgsql', 'pdo');
http://cvs.php.net/viewvc.cgi/php-src/ext/pdo_pgsql/pgsql_driver.c?r1=1.53.2.14.2.9.2.7r2=1.53.2.14.2.9.2.8diff_format=u
Index: php-src/ext/pdo_pgsql/pgsql_driver.c
diff -u php-src/ext/pdo_pgsql/pgsql_driver.c:1.53.2.14.2.9.2.7 
php-src/ext/pdo_pgsql/pgsql_driver.c:1.53.2.14.2.9.2.8
--- php-src/ext/pdo_pgsql/pgsql_driver.c:1.53.2.14.2.9.2.7  Thu Apr 30 
12:38:43 2009
+++ php-src/ext/pdo_pgsql/pgsql_driver.cThu Apr 30 12:56:00 2009
@@ -18,7 +18,7 @@
   +--+
 */
 
-/* $Id: pgsql_driver.c,v 1.53.2.14.2.9.2.7 2009/04/30 12:38:43 mbeccati Exp $ 
*/
+/* $Id: pgsql_driver.c,v 1.53.2.14.2.9.2.8 2009/04/30 12:56:00 mbeccati Exp $ 
*/
 
 #ifdef HAVE_CONFIG_H
 #include config.h
@@ -356,25 +356,9 @@
} else {
PGresult *res;
ExecStatusType status;
-#ifdef HAVE_PQEXECPARAMS
const char *q[1];
q[0] = name;
res = PQexecParams(H-server, SELECT CURRVAL($1), 1, NULL, q, 
NULL, NULL, 0);
-#else
-   char *name_escaped, *q;
-   size_t l = strlen(name);
-
-   name_escaped = safe_emalloc(l, 2, 1);
-#ifndef HAVE_PQESCAPE_CONN
-   PQescapeString(name_escaped, name, l);
-#else
-   PQescapeStringConn(H-server, name_escaped, name, l, NULL);
-#endif
-   spprintf(q, 0, SELECT CURRVAL('%s'), name_escaped);
-   res = PQexec(H-server, q);
-   efree(name_escaped); 
-   efree(q);
-#endif
status = PQresultStatus(res);
 
if (res  (status == PGRES_TUPLES_OK)) {



-- 
PHP CVS Mailing List (http://www.php.net/)
To unsubscribe, visit: http://www.php.net/unsub.php



[PHP-CVS] cvs: php-src(PHP_5_2) /ext/standard/tests/versioning php_sapi_name_variation001.phpt

2009-04-30 Thread Jani Taskinen
janiThu Apr 30 13:02:44 2009 UTC

  Modified files:  (Branch: PHP_5_2)
/php-src/ext/standard/tests/versioning  
php_sapi_name_variation001.phpt 
  Log:
  - Fix test: It is still possible to enable/disable fastcgi in PHP_5_2
  
http://cvs.php.net/viewvc.cgi/php-src/ext/standard/tests/versioning/php_sapi_name_variation001.phpt?r1=1.2.2.3r2=1.2.2.4diff_format=u
Index: php-src/ext/standard/tests/versioning/php_sapi_name_variation001.phpt
diff -u 
php-src/ext/standard/tests/versioning/php_sapi_name_variation001.phpt:1.2.2.3 
php-src/ext/standard/tests/versioning/php_sapi_name_variation001.phpt:1.2.2.4
--- 
php-src/ext/standard/tests/versioning/php_sapi_name_variation001.phpt:1.2.2.3   
Sun Apr 26 23:54:12 2009
+++ php-src/ext/standard/tests/versioning/php_sapi_name_variation001.phpt   
Thu Apr 30 13:02:43 2009
@@ -10,5 +10,5 @@
 ?php
 echo php_sapi_name();
 ?
---EXPECT--
-cgi
+--EXPECTF--
+cgi%s



-- 
PHP CVS Mailing List (http://www.php.net/)
To unsubscribe, visit: http://www.php.net/unsub.php



[PHP-CVS] cvs: php-src /ext/standard/tests/mail mail_basic2.phpt

2009-04-30 Thread Jani Taskinen
janiThu Apr 30 13:18:56 2009 UTC

  Modified files:  
/php-src/ext/standard/tests/mailmail_basic2.phpt 
  Log:
  -Fix test
  
  
http://cvs.php.net/viewvc.cgi/php-src/ext/standard/tests/mail/mail_basic2.phpt?r1=1.3r2=1.4diff_format=u
Index: php-src/ext/standard/tests/mail/mail_basic2.phpt
diff -u php-src/ext/standard/tests/mail/mail_basic2.phpt:1.3 
php-src/ext/standard/tests/mail/mail_basic2.phpt:1.4
--- php-src/ext/standard/tests/mail/mail_basic2.phpt:1.3Tue Feb 17 
15:13:20 2009
+++ php-src/ext/standard/tests/mail/mail_basic2.phptThu Apr 30 13:18:56 2009
@@ -1,12 +1,12 @@
 --TEST--
 Test mail() function : basic functionality 
---INI--
-sendmail_path=echo ---  mailBasic2.out
 --SKIPIF--
 ?php
 if(substr(PHP_OS, 0, 3) == WIN)
   die(skip Won't run on Windows);
 ?
+--INI--
+sendmail_path=echo ---  /tmp/php_test_mailBasic2.out
 --FILE--
 ?php
 /* Prototype  : int mail(string to, string subject, string message [, string 
additional_headers [, string additional_parameters]])
@@ -24,7 +24,7 @@
 $message = 'A Message';
 $additional_headers = 'KHeaders';
 $additional_parameters = Extras;
-$outFile = mailBasic2.out;
+$outFile = /tmp/php_test_mailBasic2.out;
 @unlink($outFile);
 
 echo -- extra parameters --\n;
@@ -37,7 +37,7 @@
 
 sleep(5);
 echo file_get_contents($outFile);
-//unlink($outFile);
+unlink($outFile);
 ?
 ===DONE===
 --EXPECT--



-- 
PHP CVS Mailing List (http://www.php.net/)
To unsubscribe, visit: http://www.php.net/unsub.php



[PHP-CVS] cvs: php-src(PHP_5_3) /ext/standard/tests/mail mail_basic2.phpt

2009-04-30 Thread Jani Taskinen
janiThu Apr 30 13:19:31 2009 UTC

  Modified files:  (Branch: PHP_5_3)
/php-src/ext/standard/tests/mailmail_basic2.phpt 
  Log:
  MFH:fix test
  
http://cvs.php.net/viewvc.cgi/php-src/ext/standard/tests/mail/mail_basic2.phpt?r1=1.1.2.2r2=1.1.2.3diff_format=u
Index: php-src/ext/standard/tests/mail/mail_basic2.phpt
diff -u php-src/ext/standard/tests/mail/mail_basic2.phpt:1.1.2.2 
php-src/ext/standard/tests/mail/mail_basic2.phpt:1.1.2.3
--- php-src/ext/standard/tests/mail/mail_basic2.phpt:1.1.2.2Tue Feb 17 
15:16:45 2009
+++ php-src/ext/standard/tests/mail/mail_basic2.phptThu Apr 30 13:19:31 2009
@@ -1,12 +1,12 @@
 --TEST--
 Test mail() function : basic functionality 
---INI--
-sendmail_path=echo ---  mailBasic2.out
 --SKIPIF--
 ?php
 if(substr(PHP_OS, 0, 3) == WIN)
   die(skip Won't run on Windows);
 ?
+--INI--
+sendmail_path=echo ---  /tmp/php_test_mailBasic2.out
 --FILE--
 ?php
 /* Prototype  : int mail(string to, string subject, string message [, string 
additional_headers [, string additional_parameters]])
@@ -24,7 +24,7 @@
 $message = 'A Message';
 $additional_headers = 'KHeaders';
 $additional_parameters = Extras;
-$outFile = mailBasic2.out;
+$outFile = /tmp/php_test_mailBasic2.out;
 @unlink($outFile);
 
 echo -- extra parameters --\n;
@@ -37,7 +37,7 @@
 
 sleep(5);
 echo file_get_contents($outFile);
-//unlink($outFile);
+unlink($outFile);
 ?
 ===DONE===
 --EXPECT--



-- 
PHP CVS Mailing List (http://www.php.net/)
To unsubscribe, visit: http://www.php.net/unsub.php



[PHP-CVS] cvs: php-src /ext/standard/tests/mail mail_variation2.phpt

2009-04-30 Thread Jani Taskinen
janiThu Apr 30 13:21:40 2009 UTC

  Modified files:  
/php-src/ext/standard/tests/mailmail_variation2.phpt 
  Log:
  Fix test
  
  
http://cvs.php.net/viewvc.cgi/php-src/ext/standard/tests/mail/mail_variation2.phpt?r1=1.2r2=1.3diff_format=u
Index: php-src/ext/standard/tests/mail/mail_variation2.phpt
diff -u php-src/ext/standard/tests/mail/mail_variation2.phpt:1.2 
php-src/ext/standard/tests/mail/mail_variation2.phpt:1.3
--- php-src/ext/standard/tests/mail/mail_variation2.phpt:1.2Fri Jan 23 
17:12:14 2009
+++ php-src/ext/standard/tests/mail/mail_variation2.phptThu Apr 30 
13:21:40 2009
@@ -1,7 +1,7 @@
 --TEST--
 Test mail() function : variation force extra parameters
 --INI--
-sendmail_path=echo ---  mailBasic2.out
+sendmail_path=echo ---  /tmp/php_test_mailVariation2.out
 mail.force_extra_parameters=forced params
 --SKIPIF--
 ?php
@@ -23,7 +23,7 @@
 $to = 'u...@company.com';
 $subject = 'Test Subject';
 $message = 'A Message';
-$outFile = mailBasic2.out;
+$outFile = /tmp/php_test_mailVariation2.out;
 @unlink($outFile);
 
 var_dump( mail($to, $subject, $message) );



-- 
PHP CVS Mailing List (http://www.php.net/)
To unsubscribe, visit: http://www.php.net/unsub.php



[PHP-CVS] cvs: php-src(PHP_5_3) /ext/standard exec.c

2009-04-30 Thread Pierre-Alain Joye
pajoye  Thu Apr 30 15:25:37 2009 UTC

  Modified files:  (Branch: PHP_5_3)
/php-src/ext/standard   exec.c 
  Log:
  - MFB: #45997, safe_mode bypass with exec/sytem/passthru (windows only)
  
http://cvs.php.net/viewvc.cgi/php-src/ext/standard/exec.c?r1=1.113.2.3.2.1.2.16r2=1.113.2.3.2.1.2.17diff_format=u
Index: php-src/ext/standard/exec.c
diff -u php-src/ext/standard/exec.c:1.113.2.3.2.1.2.16 
php-src/ext/standard/exec.c:1.113.2.3.2.1.2.17
--- php-src/ext/standard/exec.c:1.113.2.3.2.1.2.16  Sun Apr 19 14:59:52 2009
+++ php-src/ext/standard/exec.c Thu Apr 30 15:25:37 2009
@@ -16,7 +16,7 @@
| Ilia Alshanetsky il...@php.net |
+--+
  */
-/* $Id: exec.c,v 1.113.2.3.2.1.2.16 2009/04/19 14:59:52 iliaa Exp $ */
+/* $Id: exec.c,v 1.113.2.3.2.1.2.17 2009/04/30 15:25:37 pajoye Exp $ */
 
 #include stdio.h
 #include php.h
@@ -79,7 +79,16 @@
php_error_docref(NULL TSRMLS_CC, E_WARNING, No '..' 
components allowed in path);
goto err;
}
+   
b = strrchr(cmd, PHP_DIR_SEPARATOR);
+
+#ifdef PHP_WIN32
+   if (b  *b == '\\'  b == cmd) {
+   php_error_docref(NULL TSRMLS_CC, E_WARNING, Invalid 
absolute path.);
+   goto err;
+   }
+#endif
+
spprintf(d, 0, %s%s%s%s%s, PG(safe_mode_exec_dir), (b ?  : 
/), (b ? b : cmd), (c ?   : ), (c ? c : ));
if (c) {
*(c - 1) = ' ';



-- 
PHP CVS Mailing List (http://www.php.net/)
To unsubscribe, visit: http://www.php.net/unsub.php



[PHP-CVS] cvs: php-src(PHP_5_2) / NEWS

2009-04-30 Thread Pierre-Alain Joye
pajoye  Thu Apr 30 15:26:55 2009 UTC

  Modified files:  (Branch: PHP_5_2)
/php-srcNEWS 
  Log:
  - 45997
  
http://cvs.php.net/viewvc.cgi/php-src/NEWS?r1=1.2027.2.547.2.1480r2=1.2027.2.547.2.1481diff_format=u
Index: php-src/NEWS
diff -u php-src/NEWS:1.2027.2.547.2.1480 php-src/NEWS:1.2027.2.547.2.1481
--- php-src/NEWS:1.2027.2.547.2.1480Wed Apr 29 21:56:12 2009
+++ php-src/NEWSThu Apr 30 15:26:54 2009
@@ -57,6 +57,8 @@
 - Fixed bug #47254 (Wrong Reflection for extends class). (Felipe)
 - Fixed bug #46882 (Serialize / Unserialize misbehaviour under OS with
   different bit numbers). (Matt)
+- Fixed bug #45997 (safe_mode bypass with exec/sytem/passthru (windows only)).
+  (Pierre)
 - Fixed bug #45799 (imagepng() crashes on empty image). (Martin McNickle,
   Takeshi Abe)
 - Fixed bug #43073 (TrueType bounding box is wrong for angle0).



-- 
PHP CVS Mailing List (http://www.php.net/)
To unsubscribe, visit: http://www.php.net/unsub.php



[PHP-CVS] cvs: php-src(PHP_5_2) / NEWS

2009-04-30 Thread Ilia Alshanetsky
iliaa   Thu Apr 30 17:43:27 2009 UTC

  Modified files:  (Branch: PHP_5_2)
/php-srcNEWS 
  Log:
  
  Fixed typo
  
http://cvs.php.net/viewvc.cgi/php-src/NEWS?r1=1.2027.2.547.2.1481r2=1.2027.2.547.2.1482diff_format=u
Index: php-src/NEWS
diff -u php-src/NEWS:1.2027.2.547.2.1481 php-src/NEWS:1.2027.2.547.2.1482
--- php-src/NEWS:1.2027.2.547.2.1481Thu Apr 30 15:26:54 2009
+++ php-src/NEWSThu Apr 30 17:43:25 2009
@@ -57,7 +57,7 @@
 - Fixed bug #47254 (Wrong Reflection for extends class). (Felipe)
 - Fixed bug #46882 (Serialize / Unserialize misbehaviour under OS with
   different bit numbers). (Matt)
-- Fixed bug #45997 (safe_mode bypass with exec/sytem/passthru (windows only)).
+- Fixed bug #45997 (safe_mode bypass with exec/system/passthru (windows only)).
   (Pierre)
 - Fixed bug #45799 (imagepng() crashes on empty image). (Martin McNickle,
   Takeshi Abe)



-- 
PHP CVS Mailing List (http://www.php.net/)
To unsubscribe, visit: http://www.php.net/unsub.php



[PHP-CVS] cvs: php-src(PHP_5_2) / NEWS /ext/imap php_imap.c

2009-04-30 Thread Pierre-Alain Joye
pajoye  Thu Apr 30 18:55:44 2009 UTC

  Modified files:  (Branch: PHP_5_2)
/php-srcNEWS 
/php-src/ext/imap   php_imap.c 
  Log:
  - #47940, memory leaks in imap_body
  
http://cvs.php.net/viewvc.cgi/php-src/NEWS?r1=1.2027.2.547.2.1482r2=1.2027.2.547.2.1483diff_format=u
Index: php-src/NEWS
diff -u php-src/NEWS:1.2027.2.547.2.1482 php-src/NEWS:1.2027.2.547.2.1483
--- php-src/NEWS:1.2027.2.547.2.1482Thu Apr 30 17:43:25 2009
+++ php-src/NEWSThu Apr 30 18:55:44 2009
@@ -17,6 +17,7 @@
 - Fixed bug #47969 (ezmlm_hash() returns different values depend on OS).
   (Ilia)
 - Fixed bug #47946 (ImageConvolution overwrites background). (Ilia)
+- Fixed bug #47940 (memory leaks in imap_body). (Pierre, Jake Levitt)
 - Fixed bug #47937 (system() calls sapi_flush() regardless of output
   buffering). (Ilia)
 - Fixed bug #47903 (@ operator does not work with string offsets). (Felipe)
http://cvs.php.net/viewvc.cgi/php-src/ext/imap/php_imap.c?r1=1.208.2.7.2.50r2=1.208.2.7.2.51diff_format=u
Index: php-src/ext/imap/php_imap.c
diff -u php-src/ext/imap/php_imap.c:1.208.2.7.2.50 
php-src/ext/imap/php_imap.c:1.208.2.7.2.51
--- php-src/ext/imap/php_imap.c:1.208.2.7.2.50  Tue Apr 28 12:43:10 2009
+++ php-src/ext/imap/php_imap.c Thu Apr 30 18:55:44 2009
@@ -26,7 +26,7 @@
| PHP 4.0 updates:  Zeev Suraski z...@zend.com   |
+--+
  */
-/* $Id: php_imap.c,v 1.208.2.7.2.50 2009/04/28 12:43:10 pajoye Exp $ */
+/* $Id: php_imap.c,v 1.208.2.7.2.51 2009/04/30 18:55:44 pajoye Exp $ */
 
 #define IMAP41
 
@@ -487,7 +487,7 @@
REGISTER_LONG_CONSTANT(NIL, NIL, CONST_PERSISTENT | CONST_CS);
 
/* plug in our gets */
-   mail_parameters(NIL, SET_GETS, (void *) php_mail_gets);
+   mail_parameters(NIL, SET_GETS, (void *) NIL);
 
/* set default timeout values */
mail_parameters(NIL, SET_OPENTIMEOUT, (void *) 
FG(default_socket_timeout));
@@ -1266,7 +1266,6 @@
} else {
RETVAL_STRINGL(body, body_len, 1);
}
-   free(body);
 }
 /* }}} */
 
@@ -1995,7 +1994,9 @@
}
 
IMAPG(gets_stream) = writer;
+   mail_parameters(NIL, SET_GETS, (void *) php_mail_gets);
mail_fetchbody_full(imap_ptr-imap_stream, msgno, section, NULL, flags);
+   mail_parameters(NIL, SET_GETS, (void *) NIL);
IMAPG(gets_stream) = NULL;
 
if (close_stream) {



-- 
PHP CVS Mailing List (http://www.php.net/)
To unsubscribe, visit: http://www.php.net/unsub.php



[PHP-CVS] cvs: php-src(PHP_5_3) /ext/imap php_imap.c

2009-04-30 Thread Pierre-Alain Joye
pajoye  Thu Apr 30 18:56:25 2009 UTC

  Modified files:  (Branch: PHP_5_3)
/php-src/ext/imap   php_imap.c 
  Log:
  - MFB: #47940, memory leaks in imap_body
  
http://cvs.php.net/viewvc.cgi/php-src/ext/imap/php_imap.c?r1=1.208.2.7.2.26.2.43r2=1.208.2.7.2.26.2.44diff_format=u
Index: php-src/ext/imap/php_imap.c
diff -u php-src/ext/imap/php_imap.c:1.208.2.7.2.26.2.43 
php-src/ext/imap/php_imap.c:1.208.2.7.2.26.2.44
--- php-src/ext/imap/php_imap.c:1.208.2.7.2.26.2.43 Tue Apr 28 08:29:55 2009
+++ php-src/ext/imap/php_imap.c Thu Apr 30 18:56:25 2009
@@ -26,7 +26,7 @@
| PHP 4.0 updates:  Zeev Suraski z...@zend.com   |
+--+
  */
-/* $Id: php_imap.c,v 1.208.2.7.2.26.2.43 2009/04/28 08:29:55 pajoye Exp $ */
+/* $Id: php_imap.c,v 1.208.2.7.2.26.2.44 2009/04/30 18:56:25 pajoye Exp $ */
 
 #define IMAP41
 
@@ -850,7 +850,7 @@
REGISTER_LONG_CONSTANT(NIL, NIL, CONST_PERSISTENT | CONST_CS);
 
/* plug in our gets */
-   mail_parameters(NIL, SET_GETS, (void *) php_mail_gets);
+   mail_parameters(NIL, SET_GETS, (void *) NULL);
 
/* set default timeout values */
mail_parameters(NIL, SET_OPENTIMEOUT, (void *) 
FG(default_socket_timeout));
@@ -2330,7 +2330,9 @@
}
 
IMAPG(gets_stream) = writer;
+   mail_parameters(NIL, SET_GETS, (void *) php_mail_gets);
mail_fetchbody_full(imap_ptr-imap_stream, msgno, section, NULL, flags);
+   mail_parameters(NIL, SET_GETS, (void *) NULL);
IMAPG(gets_stream) = NULL;
 
if (close_stream) {



-- 
PHP CVS Mailing List (http://www.php.net/)
To unsubscribe, visit: http://www.php.net/unsub.php



[PHP-CVS] cvs: php-src /ext/imap php_imap.c

2009-04-30 Thread Pierre-Alain Joye
pajoye  Thu Apr 30 18:57:50 2009 UTC

  Modified files:  
/php-src/ext/imap   php_imap.c 
  Log:
  - MFB: #47940, memory leaks in imap_body
  
http://cvs.php.net/viewvc.cgi/php-src/ext/imap/php_imap.c?r1=1.284r2=1.285diff_format=u
Index: php-src/ext/imap/php_imap.c
diff -u php-src/ext/imap/php_imap.c:1.284 php-src/ext/imap/php_imap.c:1.285
--- php-src/ext/imap/php_imap.c:1.284   Tue Apr 28 08:30:10 2009
+++ php-src/ext/imap/php_imap.c Thu Apr 30 18:57:50 2009
@@ -26,7 +26,7 @@
| PHP 4.0 updates:  Zeev Suraski z...@zend.com   |
+--+
  */
-/* $Id: php_imap.c,v 1.284 2009/04/28 08:30:10 pajoye Exp $ */
+/* $Id: php_imap.c,v 1.285 2009/04/30 18:57:50 pajoye Exp $ */
 
 #define IMAP41
 
@@ -850,7 +850,7 @@
REGISTER_LONG_CONSTANT(NIL, NIL, CONST_PERSISTENT | CONST_CS);
 
/* plug in our gets */
-   mail_parameters(NIL, SET_GETS, (void *) php_mail_gets);
+   mail_parameters(NIL, SET_GETS, (void *) NIL);
 
/* set default timeout values */
mail_parameters(NIL, SET_OPENTIMEOUT, (void *) 
FG(default_socket_timeout));
@@ -2326,7 +2326,9 @@
}
 
IMAPG(gets_stream) = writer;
+   mail_parameters(NIL, SET_GETS, (void *) php_mail_gets);
mail_fetchbody_full(imap_ptr-imap_stream, msgno, section, NULL, flags);
+   mail_parameters(NIL, SET_GETS, (void *) NIL);
IMAPG(gets_stream) = NULL;
 
if (close_stream) {



-- 
PHP CVS Mailing List (http://www.php.net/)
To unsubscribe, visit: http://www.php.net/unsub.php



[PHP-CVS] cvs: phpruntests /src/testcase rtTestConfiguration.php

2009-04-30 Thread Zoe Slattery
zoe Thu Apr 30 19:06:51 2009 UTC

  Modified files:  
/phpruntests/src/testcase   rtTestConfiguration.php 
  Log:
  gzip_post modifications
  
http://cvs.php.net/viewvc.cgi/phpruntests/src/testcase/rtTestConfiguration.php?r1=1.9r2=1.10diff_format=u
Index: phpruntests/src/testcase/rtTestConfiguration.php
diff -u phpruntests/src/testcase/rtTestConfiguration.php:1.9 
phpruntests/src/testcase/rtTestConfiguration.php:1.10
--- phpruntests/src/testcase/rtTestConfiguration.php:1.9Tue Apr 28 
20:57:35 2009
+++ phpruntests/src/testcase/rtTestConfiguration.phpThu Apr 30 19:06:50 2009
@@ -69,6 +69,9 @@
if (array_key_exists('POST', $sections)) {
 $this-environmentVariables = 
array_merge($this-environmentVariables, $sections['POST']-getPostVariables());
 }
+   if (array_key_exists('GZIP_POST', $sections)) {
+$this-environmentVariables = 
array_merge($this-environmentVariables, 
$sections['GZIP_POST']-getPostVariables());
+}
 
 }
 
@@ -106,6 +109,9 @@
 if(in_array('POST', $sectionHeadings)) {
 $this-inputFileString = ' '.$sections['POST']-getPostFileName();
 }
+if(in_array('GZIP_POST', $sectionHeadings)) {
+$this-inputFileString = ' 
'.$sections['GZIP_POST']-getPostFileName();
+}
 }
 
 private function isCgiTest($sectionHeadings)



-- 
PHP CVS Mailing List (http://www.php.net/)
To unsubscribe, visit: http://www.php.net/unsub.php



[PHP-CVS] cvs: phpruntests /src/testcase/sections rtSection.php

2009-04-30 Thread Zoe Slattery
zoe Thu Apr 30 19:07:22 2009 UTC

  Modified files:  
/phpruntests/src/testcase/sections  rtSection.php 
  Log:
  gzip_post modifications
  
http://cvs.php.net/viewvc.cgi/phpruntests/src/testcase/sections/rtSection.php?r1=1.4r2=1.5diff_format=u
Index: phpruntests/src/testcase/sections/rtSection.php
diff -u phpruntests/src/testcase/sections/rtSection.php:1.4 
phpruntests/src/testcase/sections/rtSection.php:1.5
--- phpruntests/src/testcase/sections/rtSection.php:1.4 Tue Apr 28 20:58:00 2009
+++ phpruntests/src/testcase/sections/rtSection.php Thu Apr 30 19:07:22 2009
@@ -19,7 +19,8 @@
 'CLEAN'   = 'rtCleanSection',
 'XFAIL'   = 'rtXfailSection',
 'GET' = 'rtGetSection',
-'POST' = 'rtPostSection',
+'POST'= 'rtPostSection',
+'GZIP_POST'   = 'rtGzipPostSection',
 );
 
 protected $sectionName;



-- 
PHP CVS Mailing List (http://www.php.net/)
To unsubscribe, visit: http://www.php.net/unsub.php



[PHP-CVS] cvs: phpruntests /tests/testcase rtGzipPostExecutionTest.php

2009-04-30 Thread Zoe Slattery
zoe Thu Apr 30 19:07:43 2009 UTC

  Added files: 
/phpruntests/tests/testcase rtGzipPostExecutionTest.php 
  Log:
  gzip_post modifications
  

http://cvs.php.net/viewvc.cgi/phpruntests/tests/testcase/rtGzipPostExecutionTest.php?view=markuprev=1.1
Index: phpruntests/tests/testcase/rtGzipPostExecutionTest.php
+++ phpruntests/tests/testcase/rtGzipPostExecutionTest.php
?php

require_once 'PHPUnit/Framework.php';
require_once dirname(__FILE__) . '../../../src/rtAutoload.php';

class rtGzipPostExecutionTest extends PHPUnit_Framework_TestCase
{
private $sample_test;

public function setUp()
{
$this-php = trim(shell_exec(which php));
$this-php_cgi = trim(shell_exec(which php-cgi));

$this-path_to_tests = realpath(dirname(__FILE__) . 
'/../../phpt-tests');
$this-sample_test = $this-path_to_tests . '/sample_gzippost.phpt';
}

public function tearDown()
{
@unlink($this-path-to_tests . '/sample_gzippost.php');
}

public function testFileRun()
{ 
//Create a new test configuration
$config = rtRuntestsConfiguration::getInstance(array('run-tests.php', 
'-p', $this-php, $this-sample_test));

$config-setEnvironmentVariable('TEST_PHP_CGI_EXECUTABLE',$this-php_cgi);
$config-configure();

//Retrieve the array of test file names
$testFiles = $config-getSetting('TestFiles');

//Read the test file
$testFile = new rtPhpTestFile();
$testFile-doRead($testFiles[0]);
$testFile-normaliseLineEndings();

//Create a new test case
$testCase = new rtPhpTest($testFile-getContents(), 
$testFile-getTestName(), $testFile-getSectionHeadings(), $config);  

//Setup and set the local environment for the test case
$testCase-executeTest($config);
$output = $testCase-getOutput();
$status = $testCase-getStatus();
   
$this-assertEquals('It worked!', trim($output));
$this-assertEquals('', $status['pass']);


}
}

?
?


-- 
PHP CVS Mailing List (http://www.php.net/)
To unsubscribe, visit: http://www.php.net/unsub.php



[PHP-CVS] cvs: phpruntests /phpt-tests sample_gzippost.phpt

2009-04-30 Thread Zoe Slattery
zoe Thu Apr 30 19:08:20 2009 UTC

  Modified files:  
/phpruntests/phpt-tests sample_gzippost.phpt 
  Log:
  gzip_post modifications
  
http://cvs.php.net/viewvc.cgi/phpruntests/phpt-tests/sample_gzippost.phpt?r1=1.3r2=1.4diff_format=u
Index: phpruntests/phpt-tests/sample_gzippost.phpt
diff -u phpruntests/phpt-tests/sample_gzippost.phpt:1.3 
phpruntests/phpt-tests/sample_gzippost.phpt:1.4
--- phpruntests/phpt-tests/sample_gzippost.phpt:1.3 Thu Apr 23 20:31:59 2009
+++ phpruntests/phpt-tests/sample_gzippost.phpt Thu Apr 30 19:08:20 2009
@@ -1,9 +1,7 @@
 --TEST--
 Sample test for GZIP_POST
---POST--
-blahblah=blah
 --GZIP_POST--
-1
+blahblah=blah
 --FILE--
 ?php
 $content = file_get_contents('php://input');



-- 
PHP CVS Mailing List (http://www.php.net/)
To unsubscribe, visit: http://www.php.net/unsub.php



[PHP-CVS] cvs: phpruntests /src rtClassMap.php /src/testcase/sections/configurationsections rtDeflatePostSection.php /tests/testcase/sections/configurationsections rtDeflatePostSectionTest.php

2009-04-30 Thread Zoe Slattery
zoe Thu Apr 30 20:07:43 2009 UTC

  Added files: 
/phpruntests/src/testcase/sections/configurationsections

rtDeflatePostSection.php 
/phpruntests/tests/testcase/sections/configurationsections  

rtDeflatePostSectionTest.php 

  Modified files:  
/phpruntests/srcrtClassMap.php 
  Log:
  deflate post section
  
http://cvs.php.net/viewvc.cgi/phpruntests/src/rtClassMap.php?r1=1.4r2=1.5diff_format=u
Index: phpruntests/src/rtClassMap.php
diff -u phpruntests/src/rtClassMap.php:1.4 phpruntests/src/rtClassMap.php:1.5
--- phpruntests/src/rtClassMap.php:1.4  Thu Apr 30 08:12:32 2009
+++ phpruntests/src/rtClassMap.php  Thu Apr 30 20:07:43 2009
@@ -56,6 +56,7 @@
 'rtTestPreCondition'   = 
'testcase/rtTestPreCondition.php',
 'rtTestResults'= 'testcase/rtTestResults.php',
 'rtArgsSection'= 
'testcase/sections/configurationsections/rtArgsSection.php',
+'rtDeflatePostSection' = 
'testcase/sections/configurationsections/rtDeflatePostSection.php',
 'rtEnvSection' = 
'testcase/sections/configurationsections/rtEnvSection.php',
 'rtGetSection' = 
'testcase/sections/configurationsections/rtGetSection.php',
 'rtGzipPostSection'= 
'testcase/sections/configurationsections/rtGzipPostSection.php',

http://cvs.php.net/viewvc.cgi/phpruntests/src/testcase/sections/configurationsections/rtDeflatePostSection.php?view=markuprev=1.1
Index: 
phpruntests/src/testcase/sections/configurationsections/rtDeflatePostSection.php
+++ 
phpruntests/src/testcase/sections/configurationsections/rtDeflatePostSection.php
?php
/**
 * rtPostSection
 * Sets environment variables for DEFLATE_POST section
 *
 *
 * @category  Testing
 * @package   RUNTESTS
 * @authorZoe Slattery z...@php.net
 * @authorStefan Priebsch sprieb...@php.net
 * @copyright 2009 The PHP Group
 * @license   http://www.php.net/license/3_01.txt PHP License 3.01
 * @link  http://qa.php.net/
 */
class rtDeflatePostSection extends rtConfigurationSection
{
private $postVariables = array();
private $postFileName;

protected function init()
{ 
$postString = implode('\n', $this-sectionContents);
$compressedPostString = gzcompress($postString);

$this-postVariables['CONTENT_TYPE'] = 
'application/x-www-form-urlencoded';
$this-postVariables['CONTENT_LENGTH'] = strlen($compressedPostString);
$this-postVariables['REQUEST_METHOD'] = 'POST';

$this-postFileName = tempnam(sys_get_temp_dir(), 'post');

file_put_contents($this-postFileName, $compressedPostString);
}

/**
 * Additional POST environment variables required by the test
 *
 * @return array
 */
public function getPostVariables()
{
return $this-postVariables;
}

public function getPostFileName()
{
return $this-postFileName;
}
}
?
http://cvs.php.net/viewvc.cgi/phpruntests/tests/testcase/sections/configurationsections/rtDeflatePostSectionTest.php?view=markuprev=1.1
Index: 
phpruntests/tests/testcase/sections/configurationsections/rtDeflatePostSectionTest.php
+++ 
phpruntests/tests/testcase/sections/configurationsections/rtDeflatePostSectionTest.php
?php
require_once 'PHPUnit/Framework.php';
require_once dirname(__FILE__) . '../../../../../src/rtAutoload.php';

class rtDeflatePostSectionTest extends PHPUnit_Framework_TestCase
{
public function testCreateInstance() 
{
$postSection = new rtDeflatePostSection('GZIP_POST', 
array('hello=Worldgoodbye=MrChips'));  

$envVars = $postSection-getPostVariables();
$this-assertEquals('POST', $envVars['REQUEST_METHOD']);

$this-assertEquals('application/x-www-form-urlencoded',$envVars['CONTENT_TYPE']);
$this-assertEquals(strlen(gzcompress('hello=Worldgoodbye=MrChips')), 
$envVars['CONTENT_LENGTH']);

$fileName = $postSection-getPostFileName();
$string = file_get_contents($fileName);

$expectedString = gzcompress('hello=Worldgoodbye=MrChips');

$this-assertEquals($expectedString, $string);
}
}
?


-- 
PHP CVS Mailing List (http://www.php.net/)
To unsubscribe, visit: http://www.php.net/unsub.php



[PHP-CVS] cvs: phpruntests /src/testcase rtTestConfiguration.php /src/testcase/preconditions rtIsSectionImplemented.php /src/testcase/sections rtSection.php /tests/testcase rtDeflatePostExecutionTe

2009-04-30 Thread Zoe Slattery
zoe Thu Apr 30 20:22:22 2009 UTC

  Added files: 
/phpruntests/tests/testcase rtDeflatePostExecutionTest.php 

  Modified files:  
/phpruntests/src/testcase/preconditions rtIsSectionImplemented.php 
/phpruntests/src/testcase   rtTestConfiguration.php 
/phpruntests/src/testcase/sections  rtSection.php 
  Log:
  Deflate post section done
  
http://cvs.php.net/viewvc.cgi/phpruntests/src/testcase/preconditions/rtIsSectionImplemented.php?r1=1.4r2=1.5diff_format=u
Index: phpruntests/src/testcase/preconditions/rtIsSectionImplemented.php
diff -u phpruntests/src/testcase/preconditions/rtIsSectionImplemented.php:1.4 
phpruntests/src/testcase/preconditions/rtIsSectionImplemented.php:1.5
--- phpruntests/src/testcase/preconditions/rtIsSectionImplemented.php:1.4   
Tue Apr 28 20:57:48 2009
+++ phpruntests/src/testcase/preconditions/rtIsSectionImplemented.php   Thu Apr 
30 20:22:22 2009
@@ -18,7 +18,9 @@
 'CLEAN'   = 'rtCleanSection',
 'XFAIL'   = 'rtXfailSection',
 'GET' = 'rtGetSection',
-'POST'   = 'rtPostSection'
+'POST'= 'rtPostSection',
+'GZIP_POST'   = 'rtGzipPostSection',
+'DEFLATE_POST'   = 'rtDeflatePostSection',
 );
 
 /** Return the message associated with an unimplemented test section
http://cvs.php.net/viewvc.cgi/phpruntests/src/testcase/rtTestConfiguration.php?r1=1.10r2=1.11diff_format=u
Index: phpruntests/src/testcase/rtTestConfiguration.php
diff -u phpruntests/src/testcase/rtTestConfiguration.php:1.10 
phpruntests/src/testcase/rtTestConfiguration.php:1.11
--- phpruntests/src/testcase/rtTestConfiguration.php:1.10   Thu Apr 30 
19:06:50 2009
+++ phpruntests/src/testcase/rtTestConfiguration.phpThu Apr 30 20:22:22 2009
@@ -66,12 +66,15 @@
 if (array_key_exists('GET', $sections)) {
 $this-environmentVariables = 
array_merge($this-environmentVariables, $sections['GET']-getGetVariables());
 }
-   if (array_key_exists('POST', $sections)) {
+if (array_key_exists('POST', $sections)) {
 $this-environmentVariables = 
array_merge($this-environmentVariables, $sections['POST']-getPostVariables());
 }
-   if (array_key_exists('GZIP_POST', $sections)) {
+if (array_key_exists('GZIP_POST', $sections)) {
 $this-environmentVariables = 
array_merge($this-environmentVariables, 
$sections['GZIP_POST']-getPostVariables());
 }
+if (array_key_exists('DEFLATE_POST', $sections)) {
+$this-environmentVariables = 
array_merge($this-environmentVariables, 
$sections['DEFLATE_POST']-getPostVariables());
+}
 
 }
 
@@ -112,6 +115,9 @@
 if(in_array('GZIP_POST', $sectionHeadings)) {
 $this-inputFileString = ' 
'.$sections['GZIP_POST']-getPostFileName();
 }
+if(in_array('DEFLATE_POST', $sectionHeadings)) {
+$this-inputFileString = ' 
'.$sections['DEFLATE_POST']-getPostFileName();
+}
 }
 
 private function isCgiTest($sectionHeadings)
http://cvs.php.net/viewvc.cgi/phpruntests/src/testcase/sections/rtSection.php?r1=1.5r2=1.6diff_format=u
Index: phpruntests/src/testcase/sections/rtSection.php
diff -u phpruntests/src/testcase/sections/rtSection.php:1.5 
phpruntests/src/testcase/sections/rtSection.php:1.6
--- phpruntests/src/testcase/sections/rtSection.php:1.5 Thu Apr 30 19:07:22 2009
+++ phpruntests/src/testcase/sections/rtSection.php Thu Apr 30 20:22:22 2009
@@ -21,6 +21,7 @@
 'GET' = 'rtGetSection',
 'POST'= 'rtPostSection',
 'GZIP_POST'   = 'rtGzipPostSection',
+'DEFLATE_POST'  = 'rtDeflatePostSection',
 );
 
 protected $sectionName;

http://cvs.php.net/viewvc.cgi/phpruntests/tests/testcase/rtDeflatePostExecutionTest.php?view=markuprev=1.1
Index: phpruntests/tests/testcase/rtDeflatePostExecutionTest.php
+++ phpruntests/tests/testcase/rtDeflatePostExecutionTest.php
?php

require_once 'PHPUnit/Framework.php';
require_once dirname(__FILE__) . '../../../src/rtAutoload.php';

class rtDeflatePostExecutionTest extends PHPUnit_Framework_TestCase
{
private $sample_test;

public function setUp()
{
$this-php = trim(shell_exec(which php));
$this-php_cgi = trim(shell_exec(which php-cgi));

$this-path_to_tests = realpath(dirname(__FILE__) . 
'/../../phpt-tests');
$this-sample_test = $this-path_to_tests . '/sample_deflatepost.phpt';
}

public function tearDown()
{
@unlink($this-path-to_tests . '/sample_deflatepost.php');
}

public function testFileRun()
{ 
//Create a new test configuration
$config = rtRuntestsConfiguration::getInstance(array('run-tests.php', 
'-p', $this-php, $this-sample_test));

$config-setEnvironmentVariable('TEST_PHP_CGI_EXECUTABLE',$this-php_cgi);
$config-configure();

//Retrieve the array of test file names

[PHP-CVS] cvs: php-src /main rfc1867.c

2009-04-30 Thread Arnaud Le Blanc
lbarnaudFri May  1 00:13:22 2009 UTC

  Modified files:  
/php-src/main   rfc1867.c 
  Log:
  Removed code handling non-unicode input (was used when !UG(unicode))
  
  http://cvs.php.net/viewvc.cgi/php-src/main/rfc1867.c?r1=1.206r2=1.207diff_format=u
Index: php-src/main/rfc1867.c
diff -u php-src/main/rfc1867.c:1.206 php-src/main/rfc1867.c:1.207
--- php-src/main/rfc1867.c:1.206Thu Mar 26 20:02:53 2009
+++ php-src/main/rfc1867.c  Fri May  1 00:13:22 2009
@@ -17,7 +17,7 @@
+--+
  */
 
-/* $Id: rfc1867.c,v 1.206 2009/03/26 20:02:53 felipe Exp $ */
+/* $Id: rfc1867.c,v 1.207 2009/05/01 00:13:22 lbarnaud Exp $ */
 
 /*
  *  This product includes software developed by the Apache Group
@@ -49,63 +49,6 @@
if (mbuff) efree(mbuff); \
return; }
 
-#if HAVE_MBSTRING  !defined(COMPILE_DL_MBSTRING)
-#include ext/mbstring/mbstring.h
-
-static void safe_php_register_variable(char *var, char *strval, int val_len, 
zval *track_vars_array, zend_bool override_protection TSRMLS_DC);
-
-void php_mb_flush_gpc_variables(int num_vars, char **val_list, int *len_list, 
zval *array_ptr  TSRMLS_DC)
-{
-   int i;
-   if (php_mb_encoding_translation(TSRMLS_C)) {
-   if (num_vars  0 
-   php_mb_gpc_encoding_detector(val_list, len_list, 
num_vars, NULL TSRMLS_CC) == SUCCESS) {
-   php_mb_gpc_encoding_converter(val_list, len_list, 
num_vars, NULL, NULL TSRMLS_CC);
-   }
-   for (i=0; inum_vars; i+=2){
-   safe_php_register_variable(val_list[i], val_list[i+1], 
len_list[i+1], array_ptr, 0 TSRMLS_CC);
-   efree(val_list[i]);
-   efree(val_list[i+1]);
-   } 
-   efree(val_list);
-   efree(len_list);
-   }
-}
-
-void php_mb_gpc_realloc_buffer(char ***pval_list, int **plen_list, int 
*num_vars_max, int inc  TSRMLS_DC)
-{
-   /* allow only even increments */
-   if (inc  1) {
-   inc++;
-   }
-   (*num_vars_max) += inc;
-   *pval_list = (char **)erealloc(*pval_list, 
(*num_vars_max+2)*sizeof(char *));
-   *plen_list = (int *)erealloc(*plen_list, (*num_vars_max+2)*sizeof(int));
-}
-
-void php_mb_gpc_stack_variable(char *param, char *value, char ***pval_list, 
int **plen_list, int *num_vars, int *num_vars_max TSRMLS_DC)
-{
-   char **val_list=*pval_list;
-   int *len_list=*plen_list;
-
-   if (*num_vars=*num_vars_max){  
-   php_mb_gpc_realloc_buffer(pval_list, plen_list, num_vars_max, 
- 16 TSRMLS_CC);
-   /* in case realloc relocated the buffer */
-   val_list = *pval_list;
-   len_list = *plen_list;
-   }
-
-   val_list[*num_vars] = (char *)estrdup(param);
-   len_list[*num_vars] = strlen(param);
-   (*num_vars)++;
-   val_list[*num_vars] = (char *)estrdup(value);
-   len_list[*num_vars] = strlen(value);
-   (*num_vars)++;
-}
-
-#endif
-
 /* The longest property name we use in an uploaded file array */
 #define MAX_SIZE_OF_INDEX sizeof([tmp_name])
 
@@ -134,66 +77,6 @@
REGISTER_MAIN_LONG_CONSTANT(UPLOAD_ERR_EXTENSION,  UPLOAD_ERROR_X,  
CONST_CS | CONST_PERSISTENT);
 }
 
-static void normalize_protected_variable(char *varname TSRMLS_DC)
-{
-   char *s=varname, *index=NULL, *indexend=NULL, *p;
-   
-   /* overjump leading space */
-   while (*s == ' ') {
-   s++;
-   }
-   
-   /* and remove it */
-   if (s != varname) {
-   memmove(varname, s, strlen(s)+1);
-   }
-
-   for (p=varname; *p  *p != '['; p++) {
-   switch(*p) {
-   case ' ':
-   case '.':
-   *p='_';
-   break;
-   }
-   }
-
-   /* find index */
-   index = strchr(varname, '[');
-   if (index) {
-   index++;
-   s=index;
-   } else {
-   return;
-   }
-
-   /* done? */
-   while (index) {
-
-   while (*index == ' ' || *index == '\r' || *index == '\n' || 
*index=='\t') {
-   index++;
-   }
-   indexend = strchr(index, ']');
-   indexend = indexend ? indexend + 1 : index + strlen(index);
-   
-   if (s != index) {
-   memmove(s, index, strlen(index)+1);
-   s += indexend-index;
-   } else {
-   s = indexend;
-   }
-
-   if (*s == '[') {
-   s++;
-   index = s;
-   } else {
-   index = NULL;
-   }   
-   }
-
-   *s = '\0';
-}
-
-
 static void 

[PHP-CVS] cvs: php-src /main rfc1867.c

2009-04-30 Thread Arnaud Le Blanc
lbarnaudFri May  1 00:15:07 2009 UTC

  Modified files:  
/php-src/main   rfc1867.c 
  Log:
  Removed code for register_globals in file uploads
  
  
http://cvs.php.net/viewvc.cgi/php-src/main/rfc1867.c?r1=1.207r2=1.208diff_format=u
Index: php-src/main/rfc1867.c
diff -u php-src/main/rfc1867.c:1.207 php-src/main/rfc1867.c:1.208
--- php-src/main/rfc1867.c:1.207Fri May  1 00:13:22 2009
+++ php-src/main/rfc1867.c  Fri May  1 00:15:07 2009
@@ -17,7 +17,7 @@
+--+
  */
 
-/* $Id: rfc1867.c,v 1.207 2009/05/01 00:13:22 lbarnaud Exp $ */
+/* $Id: rfc1867.c,v 1.208 2009/05/01 00:15:07 lbarnaud Exp $ */
 
 /*
  *  This product includes software developed by the Apache Group
@@ -1136,7 +1136,6 @@
array_index = eustrndup(start_arr+1, 
array_len-2);   
}
 
-   /* Add $foo_name */
if (lbuf) {
efree(lbuf);
}
@@ -1146,9 +1145,6 @@
if (is_arr_upload) {
if (abuf) efree(abuf);
abuf = eustrndup(param, 
u_strlen(param)-array_len);
-   u_snprintf(lbuf, llen, %S_name[%S], abuf, 
array_index);
-   } else {
-   u_snprintf(lbuf, llen, %S_name, param);
}
 
/* The \ check should technically be needed for win32 
systems only where
@@ -1162,14 +1158,6 @@
s = tmp;
}
 
-   if (!is_anonymous) {
-   if (s  s  filename) {
-   safe_u_php_register_variable(lbuf, s+1, 
u_strlen(s+1), NULL, 0 TSRMLS_CC);
-   } else {
-   safe_u_php_register_variable(lbuf, 
filename, u_strlen(filename), NULL, 0 TSRMLS_CC);
-   }
-   }
-
/* Add $foo[name] */
if (is_arr_upload) {
u_snprintf(lbuf, llen, %S[name][%S], abuf, 
array_index);
@@ -1201,16 +1189,6 @@
}
}
 
-   /* Add $foo_type */
-   if (is_arr_upload) {
-   u_snprintf(lbuf, llen, %S_type[%S], abuf, 
array_index);
-   } else {
-   u_snprintf(lbuf, llen, %S_type, param);
-   }
-   if (!is_anonymous) {
-   safe_u_php_register_variable(lbuf, ucd, 
ucd_len, NULL, 0 TSRMLS_CC);
-   }
-
/* Add $foo[type] */
if (is_arr_upload) {
u_snprintf(lbuf, llen, %S[type][%S], abuf, 
array_index);
@@ -1225,11 +1203,6 @@
/* Initialize variables */
add_u_protected_variable(param TSRMLS_CC);
 
-   /* if param is of form xxx[.*] this will cut it to xxx 
*/
-   if (!is_anonymous) {
-   safe_u_php_register_variable(param, 
temp_filename, u_strlen(temp_filename), NULL, 1 TSRMLS_CC);
-   }
-
/* Add $foo[tmp_name] */
if (is_arr_upload) {
u_snprintf(lbuf, llen, %S[tmp_name][%S], 
abuf, array_index);
@@ -1264,16 +1237,6 @@
}
register_u_http_post_files_variable_ex(lbuf, 
error_type, http_post_files, 0 TSRMLS_CC);
 
-   /* Add $foo_size */
-   if (is_arr_upload) {
-   u_snprintf(lbuf, llen, %S_size[%S], 
abuf, array_index);
-   } else {
-   u_snprintf(lbuf, llen, %S_size, 
param);
-   }
-   if (!is_anonymous) {
-   safe_u_php_register_variable_ex(lbuf, 
file_size, NULL, 0 TSRMLS_CC);
-   }   
-
/* Add $foo[size] */
if (is_arr_upload) {
u_snprintf(lbuf, llen, %S[size][%S], 
abuf, array_index);



-- 
PHP CVS Mailing List (http://www.php.net/)
To unsubscribe, visit: http://www.php.net/unsub.php



[PHP-CVS] cvs: php-src /main rfc1867.c

2009-04-30 Thread Arnaud Le Blanc
lbarnaudFri May  1 00:18:10 2009 UTC

  Modified files:  
/php-src/main   rfc1867.c 
  Log:
  cleanup
  
  
http://cvs.php.net/viewvc.cgi/php-src/main/rfc1867.c?r1=1.208r2=1.209diff_format=u
Index: php-src/main/rfc1867.c
diff -u php-src/main/rfc1867.c:1.208 php-src/main/rfc1867.c:1.209
--- php-src/main/rfc1867.c:1.208Fri May  1 00:15:07 2009
+++ php-src/main/rfc1867.c  Fri May  1 00:18:09 2009
@@ -17,7 +17,7 @@
+--+
  */
 
-/* $Id: rfc1867.c,v 1.208 2009/05/01 00:15:07 lbarnaud Exp $ */
+/* $Id: rfc1867.c,v 1.209 2009/05/01 00:18:09 lbarnaud Exp $ */
 
 /*
  *  This product includes software developed by the Apache Group
@@ -202,14 +202,10 @@
UErrorCode status = U_ZERO_ERROR;
UChar *buf;
int buf_len = 0;
-   UConverter *input_conv = UG(http_input_encoding_conv);
+   UConverter *input_conv = ZEND_U_CONVERTER(UG(http_input_encoding_conv));
 
-   if (!input_conv) {
-   input_conv = ZEND_U_CONVERTER(UG(output_encoding_conv));
-   }
-
-   input_conv = ZEND_U_CONVERTER(UG(output_encoding_conv));
zend_string_to_unicode_ex(input_conv, buf, buf_len, in, in_len, 
status);
+
if (U_SUCCESS(status)) {
if (out_len)
*out_len = buf_len;
@@ -1134,6 +1130,9 @@
efree(array_index);
}
array_index = eustrndup(start_arr+1, 
array_len-2);   
+
+   if (abuf) efree(abuf);
+   abuf = eustrndup(param, 
u_strlen(param)-array_len);
}
 
if (lbuf) {
@@ -1142,11 +1141,6 @@
llen = u_strlen(param) + MAX_SIZE_OF_INDEX + 1;
lbuf = eumalloc(llen);
 
-   if (is_arr_upload) {
-   if (abuf) efree(abuf);
-   abuf = eustrndup(param, 
u_strlen(param)-array_len);
-   }
-
/* The \ check should technically be needed for win32 
systems only where
 * it is a valid path separator. However, IE in all its 
wisdom always sends
 * the full path of the file on the user's filesystem, 
which means that unless



-- 
PHP CVS Mailing List (http://www.php.net/)
To unsubscribe, visit: http://www.php.net/unsub.php



[PHP-CVS] cvs: php-src /main rfc1867.c

2009-04-30 Thread Arnaud Le Blanc
lbarnaudFri May  1 00:36:43 2009 UTC

  Modified files:  
/php-src/main   rfc1867.c 
  Log:
  revert to allow Andrei to make his changes
  
  http://cvs.php.net/viewvc.cgi/php-src/main/rfc1867.c?r1=1.209r2=1.210diff_format=u
Index: php-src/main/rfc1867.c
diff -u php-src/main/rfc1867.c:1.209 php-src/main/rfc1867.c:1.210
--- php-src/main/rfc1867.c:1.209Fri May  1 00:18:09 2009
+++ php-src/main/rfc1867.c  Fri May  1 00:36:43 2009
@@ -17,7 +17,7 @@
+--+
  */
 
-/* $Id: rfc1867.c,v 1.209 2009/05/01 00:18:09 lbarnaud Exp $ */
+/* $Id: rfc1867.c,v 1.210 2009/05/01 00:36:43 lbarnaud Exp $ */
 
 /*
  *  This product includes software developed by the Apache Group
@@ -49,6 +49,63 @@
if (mbuff) efree(mbuff); \
return; }
 
+#if HAVE_MBSTRING  !defined(COMPILE_DL_MBSTRING)
+#include ext/mbstring/mbstring.h
+
+static void safe_php_register_variable(char *var, char *strval, int val_len, 
zval *track_vars_array, zend_bool override_protection TSRMLS_DC);
+
+void php_mb_flush_gpc_variables(int num_vars, char **val_list, int *len_list, 
zval *array_ptr  TSRMLS_DC)
+{
+   int i;
+   if (php_mb_encoding_translation(TSRMLS_C)) {
+   if (num_vars  0 
+   php_mb_gpc_encoding_detector(val_list, len_list, 
num_vars, NULL TSRMLS_CC) == SUCCESS) {
+   php_mb_gpc_encoding_converter(val_list, len_list, 
num_vars, NULL, NULL TSRMLS_CC);
+   }
+   for (i=0; inum_vars; i+=2){
+   safe_php_register_variable(val_list[i], val_list[i+1], 
len_list[i+1], array_ptr, 0 TSRMLS_CC);
+   efree(val_list[i]);
+   efree(val_list[i+1]);
+   } 
+   efree(val_list);
+   efree(len_list);
+   }
+}
+
+void php_mb_gpc_realloc_buffer(char ***pval_list, int **plen_list, int 
*num_vars_max, int inc  TSRMLS_DC)
+{
+   /* allow only even increments */
+   if (inc  1) {
+   inc++;
+   }
+   (*num_vars_max) += inc;
+   *pval_list = (char **)erealloc(*pval_list, 
(*num_vars_max+2)*sizeof(char *));
+   *plen_list = (int *)erealloc(*plen_list, (*num_vars_max+2)*sizeof(int));
+}
+
+void php_mb_gpc_stack_variable(char *param, char *value, char ***pval_list, 
int **plen_list, int *num_vars, int *num_vars_max TSRMLS_DC)
+{
+   char **val_list=*pval_list;
+   int *len_list=*plen_list;
+
+   if (*num_vars=*num_vars_max){  
+   php_mb_gpc_realloc_buffer(pval_list, plen_list, num_vars_max, 
+ 16 TSRMLS_CC);
+   /* in case realloc relocated the buffer */
+   val_list = *pval_list;
+   len_list = *plen_list;
+   }
+
+   val_list[*num_vars] = (char *)estrdup(param);
+   len_list[*num_vars] = strlen(param);
+   (*num_vars)++;
+   val_list[*num_vars] = (char *)estrdup(value);
+   len_list[*num_vars] = strlen(value);
+   (*num_vars)++;
+}
+
+#endif
+
 /* The longest property name we use in an uploaded file array */
 #define MAX_SIZE_OF_INDEX sizeof([tmp_name])
 
@@ -77,6 +134,66 @@
REGISTER_MAIN_LONG_CONSTANT(UPLOAD_ERR_EXTENSION,  UPLOAD_ERROR_X,  
CONST_CS | CONST_PERSISTENT);
 }
 
+static void normalize_protected_variable(char *varname TSRMLS_DC)
+{
+   char *s=varname, *index=NULL, *indexend=NULL, *p;
+   
+   /* overjump leading space */
+   while (*s == ' ') {
+   s++;
+   }
+   
+   /* and remove it */
+   if (s != varname) {
+   memmove(varname, s, strlen(s)+1);
+   }
+
+   for (p=varname; *p  *p != '['; p++) {
+   switch(*p) {
+   case ' ':
+   case '.':
+   *p='_';
+   break;
+   }
+   }
+
+   /* find index */
+   index = strchr(varname, '[');
+   if (index) {
+   index++;
+   s=index;
+   } else {
+   return;
+   }
+
+   /* done? */
+   while (index) {
+
+   while (*index == ' ' || *index == '\r' || *index == '\n' || 
*index=='\t') {
+   index++;
+   }
+   indexend = strchr(index, ']');
+   indexend = indexend ? indexend + 1 : index + strlen(index);
+   
+   if (s != index) {
+   memmove(s, index, strlen(index)+1);
+   s += indexend-index;
+   } else {
+   s = indexend;
+   }
+
+   if (*s == '[') {
+   s++;
+   index = s;
+   } else {
+   index = NULL;
+   }   
+   }
+
+   *s = '\0';
+}
+
+
 static void 

[PHP-CVS] cvs: php-src /ext/spl/internal regexiterator.inc

2009-04-30 Thread Felipe Pena
felipe  Fri May  1 01:55:28 2009 UTC

  Modified files:  
/php-src/ext/spl/internal   regexiterator.inc 
  Log:
  - Fixed bug #48120 (Implementing abstract class FilterIterator in 
regexiterator.inc)
  
http://cvs.php.net/viewvc.cgi/php-src/ext/spl/internal/regexiterator.inc?r1=1.8r2=1.9diff_format=u
Index: php-src/ext/spl/internal/regexiterator.inc
diff -u php-src/ext/spl/internal/regexiterator.inc:1.8 
php-src/ext/spl/internal/regexiterator.inc:1.9
--- php-src/ext/spl/internal/regexiterator.inc:1.8  Fri Jul 21 21:54:49 2006
+++ php-src/ext/spl/internal/regexiterator.inc  Fri May  1 01:55:28 2009
@@ -17,7 +17,7 @@
  *
  * This filter iterator assumes that the inner iterator 
  */
-class RegexIterator implements FilterIterator
+class RegexIterator extends FilterIterator
 {
const USE_KEY = 0x0001; /** If present in $flags the the key 
is 
 used rather then the current 
value. */
@@ -160,4 +160,4 @@
}
 }
 
-?
\ No newline at end of file
+?



-- 
PHP CVS Mailing List (http://www.php.net/)
To unsubscribe, visit: http://www.php.net/unsub.php



[PHP-CVS] cvs: php-src(PHP_5_3) /ext/spl/internal regexiterator.inc

2009-04-30 Thread Felipe Pena
felipe  Fri May  1 01:55:42 2009 UTC

  Modified files:  (Branch: PHP_5_3)
/php-src/ext/spl/internal   regexiterator.inc 
  Log:
  - MFH: Fixed bug #48120 (Implementing abstract class FilterIterator in 
regexiterator.inc)
  
http://cvs.php.net/viewvc.cgi/php-src/ext/spl/internal/regexiterator.inc?r1=1.2.2.6r2=1.2.2.6.2.1diff_format=u
Index: php-src/ext/spl/internal/regexiterator.inc
diff -u php-src/ext/spl/internal/regexiterator.inc:1.2.2.6 
php-src/ext/spl/internal/regexiterator.inc:1.2.2.6.2.1
--- php-src/ext/spl/internal/regexiterator.inc:1.2.2.6  Fri Jul 21 21:55:43 2006
+++ php-src/ext/spl/internal/regexiterator.inc  Fri May  1 01:55:41 2009
@@ -17,7 +17,7 @@
  *
  * This filter iterator assumes that the inner iterator 
  */
-class RegexIterator implements FilterIterator
+class RegexIterator extends FilterIterator
 {
const USE_KEY = 0x0001; /** If present in $flags the the key 
is 
 used rather then the current 
value. */
@@ -160,4 +160,4 @@
}
 }
 
-?
\ No newline at end of file
+?



-- 
PHP CVS Mailing List (http://www.php.net/)
To unsubscribe, visit: http://www.php.net/unsub.php



[PHP-CVS] cvs: php-src(PHP_5_2) /ext/spl/internal regexiterator.inc

2009-04-30 Thread Felipe Pena
felipe  Fri May  1 01:55:52 2009 UTC

  Modified files:  (Branch: PHP_5_2)
/php-src/ext/spl/internal   regexiterator.inc 
  Log:
  - MFH: Fixed bug #48120 (Implementing abstract class FilterIterator in 
regexiterator.inc)
  
http://cvs.php.net/viewvc.cgi/php-src/ext/spl/internal/regexiterator.inc?r1=1.2.2.6r2=1.2.2.7diff_format=u
Index: php-src/ext/spl/internal/regexiterator.inc
diff -u php-src/ext/spl/internal/regexiterator.inc:1.2.2.6 
php-src/ext/spl/internal/regexiterator.inc:1.2.2.7
--- php-src/ext/spl/internal/regexiterator.inc:1.2.2.6  Fri Jul 21 21:55:43 2006
+++ php-src/ext/spl/internal/regexiterator.inc  Fri May  1 01:55:52 2009
@@ -17,7 +17,7 @@
  *
  * This filter iterator assumes that the inner iterator 
  */
-class RegexIterator implements FilterIterator
+class RegexIterator extends FilterIterator
 {
const USE_KEY = 0x0001; /** If present in $flags the the key 
is 
 used rather then the current 
value. */
@@ -160,4 +160,4 @@
}
 }
 
-?
\ No newline at end of file
+?



-- 
PHP CVS Mailing List (http://www.php.net/)
To unsubscribe, visit: http://www.php.net/unsub.php



[PHP-CVS] cvs: php-src /ext/odbc php_odbc.c

2009-04-30 Thread Felipe Pena
felipe  Fri May  1 03:02:32 2009 UTC

  Modified files:  
/php-src/ext/odbc   php_odbc.c 
  Log:
  - Fixed bug #48038 (odbc_execute changes variables used to form params array)
  
http://cvs.php.net/viewvc.cgi/php-src/ext/odbc/php_odbc.c?r1=1.218r2=1.219diff_format=u
Index: php-src/ext/odbc/php_odbc.c
diff -u php-src/ext/odbc/php_odbc.c:1.218 php-src/ext/odbc/php_odbc.c:1.219
--- php-src/ext/odbc/php_odbc.c:1.218   Tue Mar 10 23:39:27 2009
+++ php-src/ext/odbc/php_odbc.c Fri May  1 03:02:32 2009
@@ -20,7 +20,7 @@
+--+
 */
 
-/* $Id: php_odbc.c,v 1.218 2009/03/10 23:39:27 helly Exp $ */
+/* $Id: php_odbc.c,v 1.219 2009/05/01 03:02:32 felipe Exp $ */
 
 #ifdef HAVE_CONFIG_H
 #include config.h
@@ -1274,7 +1274,7 @@
}
 
otype = (*tmp)-type;
-   convert_to_string(*tmp);
+   convert_to_string_ex(tmp);
if (Z_TYPE_PP(tmp) != IS_STRING) {
php_error_docref(NULL TSRMLS_CC, 
E_WARNING,Error converting parameter);
SQLFreeStmt(result-stmt, SQL_RESET_PARAMS);



-- 
PHP CVS Mailing List (http://www.php.net/)
To unsubscribe, visit: http://www.php.net/unsub.php



[PHP-CVS] cvs: php-src(PHP_5_3) /ext/odbc php_odbc.c

2009-04-30 Thread Felipe Pena
felipe  Fri May  1 03:02:47 2009 UTC

  Modified files:  (Branch: PHP_5_3)
/php-src/ext/odbc   php_odbc.c 
  Log:
  - MFH: Fixed bug #48038 (odbc_execute changes variables used to form params 
array)
  
http://cvs.php.net/viewvc.cgi/php-src/ext/odbc/php_odbc.c?r1=1.189.2.4.2.7.2.18r2=1.189.2.4.2.7.2.19diff_format=u
Index: php-src/ext/odbc/php_odbc.c
diff -u php-src/ext/odbc/php_odbc.c:1.189.2.4.2.7.2.18 
php-src/ext/odbc/php_odbc.c:1.189.2.4.2.7.2.19
--- php-src/ext/odbc/php_odbc.c:1.189.2.4.2.7.2.18  Mon Mar 30 14:25:54 2009
+++ php-src/ext/odbc/php_odbc.c Fri May  1 03:02:46 2009
@@ -20,7 +20,7 @@
+--+
 */
 
-/* $Id: php_odbc.c,v 1.189.2.4.2.7.2.18 2009/03/30 14:25:54 kalle Exp $ */
+/* $Id: php_odbc.c,v 1.189.2.4.2.7.2.19 2009/05/01 03:02:46 felipe Exp $ */
 
 #ifdef HAVE_CONFIG_H
 #include config.h
@@ -1274,7 +1274,7 @@
}
 
otype = (*tmp)-type;
-   convert_to_string(*tmp);
+   convert_to_string_ex(tmp);
if (Z_TYPE_PP(tmp) != IS_STRING) {
php_error_docref(NULL TSRMLS_CC, 
E_WARNING,Error converting parameter);
SQLFreeStmt(result-stmt, SQL_RESET_PARAMS);



-- 
PHP CVS Mailing List (http://www.php.net/)
To unsubscribe, visit: http://www.php.net/unsub.php



[PHP-CVS] cvs: php-src(PHP_5_2) / NEWS /ext/odbc php_odbc.c

2009-04-30 Thread Felipe Pena
felipe  Fri May  1 03:06:40 2009 UTC

  Modified files:  (Branch: PHP_5_2)
/php-src/ext/odbc   php_odbc.c 
/php-srcNEWS 
  Log:
  - MFH: Fixed bug #48038 (odbc_execute changes variables used to form params 
array)
  
http://cvs.php.net/viewvc.cgi/php-src/ext/odbc/php_odbc.c?r1=1.189.2.4.2.11r2=1.189.2.4.2.12diff_format=u
Index: php-src/ext/odbc/php_odbc.c
diff -u php-src/ext/odbc/php_odbc.c:1.189.2.4.2.11 
php-src/ext/odbc/php_odbc.c:1.189.2.4.2.12
--- php-src/ext/odbc/php_odbc.c:1.189.2.4.2.11  Wed Dec 31 11:17:40 2008
+++ php-src/ext/odbc/php_odbc.c Fri May  1 03:06:38 2009
@@ -20,7 +20,7 @@
+--+
 */
 
-/* $Id: php_odbc.c,v 1.189.2.4.2.11 2008/12/31 11:17:40 sebastian Exp $ */
+/* $Id: php_odbc.c,v 1.189.2.4.2.12 2009/05/01 03:06:38 felipe Exp $ */
 
 #ifdef HAVE_CONFIG_H
 #include config.h
@@ -1035,7 +1035,7 @@
}
 
otype = (*tmp)-type;
-   convert_to_string(*tmp);
+   convert_to_string_ex(tmp);
if (Z_TYPE_PP(tmp) != IS_STRING) {
php_error_docref(NULL TSRMLS_CC, 
E_WARNING,Error converting parameter);
SQLFreeStmt(result-stmt, SQL_RESET_PARAMS);
http://cvs.php.net/viewvc.cgi/php-src/NEWS?r1=1.2027.2.547.2.1483r2=1.2027.2.547.2.1484diff_format=u
Index: php-src/NEWS
diff -u php-src/NEWS:1.2027.2.547.2.1483 php-src/NEWS:1.2027.2.547.2.1484
--- php-src/NEWS:1.2027.2.547.2.1483Thu Apr 30 18:55:44 2009
+++ php-src/NEWSFri May  1 03:06:39 2009
@@ -11,6 +11,8 @@
 - Fixed segfault on invalid session.save_path. (Hannes)
 - Fixed leaks in imap when a mail_criteria is used. (Pierre)
 
+- Fixed bug #48038 (odbc_execute changes variables used to form params array).
+  (Felipe)
 - Fixed bug #47997 (stream_copy_to_stream returns 1 on empty streams). (Arnaud)
 - Fixed bug #47991 (SSL streams fail if error stack contains items). (Mikko)
 - Fixed bug #47981 (error handler not called regardless). (Hannes)



-- 
PHP CVS Mailing List (http://www.php.net/)
To unsubscribe, visit: http://www.php.net/unsub.php