[PHP-CVS] cvs: php-src /win32/build Makefile

2008-05-07 Thread Matt Wilmas
mattwil Thu May  8 04:52:30 2008 UTC

  Modified files:  
/php-src/win32/buildMakefile 
  Log:
  Remove old references to flex.skl
  
http://cvs.php.net/viewvc.cgi/php-src/win32/build/Makefile?r1=1.45&r2=1.46&diff_format=u
Index: php-src/win32/build/Makefile
diff -u php-src/win32/build/Makefile:1.45 php-src/win32/build/Makefile:1.46
--- php-src/win32/build/Makefile:1.45   Wed Mar 26 14:46:17 2008
+++ php-src/win32/build/MakefileThu May  8 04:52:30 2008
@@ -14,7 +14,7 @@
 #  | Author: Wez Furlong <[EMAIL PROTECTED]>   |
 #  +--+
 #
-# $Id: Makefile,v 1.45 2008/03/26 14:46:17 scottmac Exp $
+# $Id: Makefile,v 1.46 2008/05/08 04:52:30 mattwil Exp $
 # This is the makefile template for the win32 build
 
 CC="$(CL)"
@@ -50,10 +50,10 @@
$(BISON) --output=Zend/zend_language_parser.c -v -d -p zend 
Zend/zend_language_parser.y
 
 !if $(RE2C) != ""
-Zend\zend_ini_scanner.c: Zend\flex.skl Zend\zend_ini_scanner.l
+Zend\zend_ini_scanner.c: Zend\zend_ini_scanner.l
$(RE2C) $(RE2C_FLAGS) --case-inverted -cbdFt 
Zend/zend_ini_scanner_defs.h -oZend/zend_ini_scanner.c Zend/zend_ini_scanner.l
 
-Zend\zend_language_scanner.c: Zend\flex.skl Zend\zend_language_scanner.l
+Zend\zend_language_scanner.c: Zend\zend_language_scanner.l
$(RE2C) $(RE2C_FLAGS) --case-inverted -cbdFt 
Zend/zend_language_scanner_defs.h -oZend/zend_language_scanner.c 
Zend/zend_language_scanner.l
 !endif
 



-- 
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 math.c

2008-05-07 Thread Matt Wilmas
mattwil Thu May  8 04:23:26 2008 UTC

  Modified files:  (Branch: PHP_5_3)
/php-src/ext/standard   math.c 
  Log:
  Fix build
  
http://cvs.php.net/viewvc.cgi/php-src/ext/standard/math.c?r1=1.131.2.2.2.6.2.7&r2=1.131.2.2.2.6.2.8&diff_format=u
Index: php-src/ext/standard/math.c
diff -u php-src/ext/standard/math.c:1.131.2.2.2.6.2.7 
php-src/ext/standard/math.c:1.131.2.2.2.6.2.8
--- php-src/ext/standard/math.c:1.131.2.2.2.6.2.7   Tue May  6 10:55:49 2008
+++ php-src/ext/standard/math.c Thu May  8 04:23:26 2008
@@ -19,7 +19,7 @@
+--+
 */
 
-/* $Id: math.c,v 1.131.2.2.2.6.2.7 2008/05/06 10:55:49 kalle Exp $ */
+/* $Id: math.c,v 1.131.2.2.2.6.2.8 2008/05/08 04:23:26 mattwil Exp $ */
 
 #include "php.h"
 #include "php_math.h"
@@ -354,7 +354,7 @@
if (zend_parse_parameters(ZEND_NUM_ARGS() TSRMLS_CC, "d", &num) == 
FAILURE) {
return;
}
-   RETURN_DOUBLE(asinh(num));
+   RETURN_DOUBLE(php_asinh(num));
 }
 /* }}} */
 



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



[PHP-CVS] cvs: CVSROOT / avail

2008-05-07 Thread Rasmus Lerdorf
rasmus  Thu May  8 00:48:30 2008 UTC

  Modified files:  
/CVSROOTavail 
  Log:
  Karma for Matt Wilmas
  
  
http://cvs.php.net/viewvc.cgi/CVSROOT/avail?r1=1.1392&r2=1.1393&diff_format=u
Index: CVSROOT/avail
diff -u CVSROOT/avail:1.1392 CVSROOT/avail:1.1393
--- CVSROOT/avail:1.1392Tue May  6 20:28:15 2008
+++ CVSROOT/avail   Thu May  8 00:48:30 2008
@@ -17,10 +17,10 @@
 # The PHP Developers have full access to the full source trees for
 # PHP, as well as the documentation.
 
-avail|lstrojny,dharmap,kraghuba,stevseea,colder,lwe,auroraeosrose,mike,rolland,cawa,msisolak,alan_k,rrichards,tal,mfischer,fmk,hirokawa,jah,eschmid,dbeu,sebastian,samjam,avsm,ronabob,derick,sterling,venaas,stas,hholzgra,cmv,phildriscoll,jmoore,andre,jani,sr,david,jdonagher,chagenbu,jon,elixer,joosters,jason,mysql,kalowsky,opaquedave,steinm,phanto,gluke,svanegmond,rjs,vlad,jimjag,emile,wez,sasha,camber,ohrn,romolo,martin,lurcher,wsanchez,dreid,bmcadams,swm,zhang,kevin,joey,entity,cardinal,coar,jflemer,raphael,danda,rbb,mboeren,dougm,edink,alexwaugh,bernd,zak,sesser,yohgaki,imajes,markonen,dickmeiss,helly,sander,jan,kir,aaron,jwoolley,pbannister,rvenkat,dali,rodif_bl,hyanantha,witten,georg,msopacua,mpdoremus,fujimoto,iliaa,chregu,azzit,gschlossnagle,andrey,dan,moriyoshi,dviner,bfrance,flex,iwakiri,john,harrie,pollita,ianh,k.schroeder,dcowgill,jerenkrantz,jay,ddhill,jorton,thetaphi,abies,vincent,goba,dmitry,pajoye,shie,rafi,magnus,tony2001,johannes,dbs,skoduru,nrathna,jesus,go!
 
palv,bjori,nlopess,wrowe,shire,zoe,scottmac,t2man,dsp,davidw,ab5602,nicholsr,lsmith,cellog,davidc,felipe,robinf,jmessa,philip,sixd,gwynne,ant,kalle|phpfi,php3,php-src,pecl,non-pecl,spl,phpdoc,phpdoc-ar,phpdoc-bg,phpdoc-cs,phpdoc-da,phpdoc-de,phpdoc-el,phpdoc-es,phpdoc-fa_IR,phpdoc-fi,phpdoc-fr,phpdoc-he,phpdoc-hk,phpdoc-hu,phpdoc-id,phpdoc-it,phpdoc-ja,phpdoc-kr,phpdoc-lt,phpdoc-nl,phpdoc-pl,phpdoc-pt_BR,phpdoc-pt,phpdoc-ro,phpdoc-ru,phpdoc-sk,phpdoc-sl,phpdoc-sv,phpdoc-tr,phpdoc-tw,phpdoc-zh,phpdoc-ca,phpdoc-no,phd
+avail|lstrojny,dharmap,kraghuba,stevseea,colder,lwe,auroraeosrose,mike,rolland,cawa,msisolak,alan_k,rrichards,tal,mfischer,fmk,hirokawa,jah,eschmid,dbeu,sebastian,samjam,avsm,ronabob,derick,sterling,venaas,stas,hholzgra,cmv,phildriscoll,jmoore,andre,jani,sr,david,jdonagher,chagenbu,jon,elixer,joosters,jason,mysql,kalowsky,opaquedave,steinm,phanto,gluke,svanegmond,rjs,vlad,jimjag,emile,wez,sasha,camber,ohrn,romolo,martin,lurcher,wsanchez,dreid,bmcadams,swm,zhang,kevin,joey,entity,cardinal,coar,jflemer,raphael,danda,rbb,mboeren,dougm,edink,alexwaugh,bernd,zak,sesser,yohgaki,imajes,markonen,dickmeiss,helly,sander,jan,kir,aaron,jwoolley,pbannister,rvenkat,dali,rodif_bl,hyanantha,witten,georg,msopacua,mpdoremus,fujimoto,iliaa,chregu,azzit,gschlossnagle,andrey,dan,moriyoshi,dviner,bfrance,flex,iwakiri,john,harrie,pollita,ianh,k.schroeder,dcowgill,jerenkrantz,jay,ddhill,jorton,thetaphi,abies,vincent,goba,dmitry,pajoye,shie,rafi,magnus,tony2001,johannes,dbs,skoduru,nrathna,jesus,go!
 
palv,bjori,nlopess,wrowe,shire,zoe,scottmac,t2man,dsp,davidw,ab5602,nicholsr,lsmith,cellog,davidc,felipe,robinf,jmessa,philip,sixd,gwynne,ant,kalle,mattwil|phpfi,php3,php-src,pecl,non-pecl,spl,phpdoc,phpdoc-ar,phpdoc-bg,phpdoc-cs,phpdoc-da,phpdoc-de,phpdoc-el,phpdoc-es,phpdoc-fa_IR,phpdoc-fi,phpdoc-fr,phpdoc-he,phpdoc-hk,phpdoc-hu,phpdoc-id,phpdoc-it,phpdoc-ja,phpdoc-kr,phpdoc-lt,phpdoc-nl,phpdoc-pl,phpdoc-pt_BR,phpdoc-pt,phpdoc-ro,phpdoc-ru,phpdoc-sk,phpdoc-sl,phpdoc-sv,phpdoc-tr,phpdoc-tw,phpdoc-zh,phpdoc-ca,phpdoc-no,phd
 
 # Some people have access to tests in the Engine
-avail|magnus,michael,zoe,jmessa|Zend/tests,ZendEngine2/tests
+avail|magnus,michael,zoe,jmessa,mattwil|Zend/tests,ZendEngine2/tests
 
 # fastcgi implementation for IIS
 avail|shane,wez,edink|fastcgi-isapi



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



[PHP-CVS] cvs: php-src /ext/date php_date.c

2008-05-07 Thread Ilia Alshanetsky
iliaa   Wed May  7 23:46:11 2008 UTC

  Modified files:  
/php-src/ext/date   php_date.c 
  Log:
  
  MFB: kill unused vars
  
http://cvs.php.net/viewvc.cgi/php-src/ext/date/php_date.c?r1=1.185&r2=1.186&diff_format=u
Index: php-src/ext/date/php_date.c
diff -u php-src/ext/date/php_date.c:1.185 php-src/ext/date/php_date.c:1.186
--- php-src/ext/date/php_date.c:1.185   Sun May  4 09:59:42 2008
+++ php-src/ext/date/php_date.c Wed May  7 23:46:11 2008
@@ -16,7 +16,7 @@
+--+
  */
 
-/* $Id: php_date.c,v 1.185 2008/05/04 09:59:42 derick Exp $ */
+/* $Id: php_date.c,v 1.186 2008/05/07 23:46:11 iliaa Exp $ */
 
 #include "php.h"
 #include "php_streams.h"
@@ -1728,7 +1728,6 @@
 static void date_period_it_dtor(zend_object_iterator *iter TSRMLS_DC)
 {
date_period_it *iterator = (date_period_it *)iter;
-   zval*intern = (zval*)iterator->intern.data;
 
date_period_it_invalidate_current(iter TSRMLS_CC);
 
@@ -1792,7 +1791,6 @@
 static int date_period_it_current_key(zend_object_iterator *iter, char 
**str_key, uint *str_key_len, ulong *int_key TSRMLS_DC)
 {
date_period_it   *iterator = (date_period_it *)iter;
-   php_period_obj   *object   = iterator->object;
*int_key = iterator->current_index;
return HASH_KEY_IS_LONG;
 }
@@ -1803,7 +1801,6 @@
 static void date_period_it_move_forward(zend_object_iterator *iter TSRMLS_DC)
 {
date_period_it   *iterator = (date_period_it *)iter;
-   php_period_obj   *object   = iterator->object;
 
iterator->current_index++;
date_period_it_invalidate_current(iter TSRMLS_CC);
@@ -1815,7 +1812,6 @@
 static void date_period_it_rewind(zend_object_iterator *iter TSRMLS_DC)
 {
date_period_it   *iterator = (date_period_it *)iter;
-   php_period_obj   *object   = iterator->object;
 
iterator->current_index = 0;
date_period_it_invalidate_current(iter TSRMLS_CC);



-- 
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/date php_date.c

2008-05-07 Thread Ilia Alshanetsky
iliaa   Wed May  7 23:45:28 2008 UTC

  Modified files:  (Branch: PHP_5_3)
/php-src/ext/date   php_date.c 
  Log:
  Kill unused vars
  
  
http://cvs.php.net/viewvc.cgi/php-src/ext/date/php_date.c?r1=1.43.2.45.2.51.2.37&r2=1.43.2.45.2.51.2.38&diff_format=u
Index: php-src/ext/date/php_date.c
diff -u php-src/ext/date/php_date.c:1.43.2.45.2.51.2.37 
php-src/ext/date/php_date.c:1.43.2.45.2.51.2.38
--- php-src/ext/date/php_date.c:1.43.2.45.2.51.2.37 Sun May  4 10:00:01 2008
+++ php-src/ext/date/php_date.c Wed May  7 23:45:28 2008
@@ -16,7 +16,7 @@
+--+
  */
 
-/* $Id: php_date.c,v 1.43.2.45.2.51.2.37 2008/05/04 10:00:01 derick Exp $ */
+/* $Id: php_date.c,v 1.43.2.45.2.51.2.38 2008/05/07 23:45:28 iliaa Exp $ */
 
 #include "php.h"
 #include "php_streams.h"
@@ -1602,7 +1602,6 @@
 static void date_period_it_dtor(zend_object_iterator *iter TSRMLS_DC)
 {
date_period_it *iterator = (date_period_it *)iter;
-   zval*intern = (zval*)iterator->intern.data;
 
date_period_it_invalidate_current(iter TSRMLS_CC);
 
@@ -1666,7 +1665,6 @@
 static int date_period_it_current_key(zend_object_iterator *iter, char 
**str_key, uint *str_key_len, ulong *int_key TSRMLS_DC)
 {
date_period_it   *iterator = (date_period_it *)iter;
-   php_period_obj   *object   = iterator->object;
*int_key = iterator->current_index;
return HASH_KEY_IS_LONG;
 }
@@ -1677,7 +1675,6 @@
 static void date_period_it_move_forward(zend_object_iterator *iter TSRMLS_DC)
 {
date_period_it   *iterator = (date_period_it *)iter;
-   php_period_obj   *object   = iterator->object;
 
iterator->current_index++;
date_period_it_invalidate_current(iter TSRMLS_CC);
@@ -1689,7 +1686,6 @@
 static void date_period_it_rewind(zend_object_iterator *iter TSRMLS_DC)
 {
date_period_it   *iterator = (date_period_it *)iter;
-   php_period_obj   *object   = iterator->object;
 
iterator->current_index = 0;
date_period_it_invalidate_current(iter TSRMLS_CC);



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



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

2008-05-07 Thread Ilia Alshanetsky

What libc are you using? I can't seem to reproduce the issue here...


On 7-May-08, at 4:42 AM, Antony Dovgal wrote:


On 06.05.2008 22:01, Ilia Alshanetsky wrote:

iliaa   Tue May  6 18:01:36 2008 UTC
 Modified files:  (Branch: PHP_5_3)
   /php-src/ext/standardbasic_functions.c   Log:
 Fixed bug #44836 (putenv() crashes, avoid direct reference of  
environ in

 POSIX systems)
   # Original patch by delphij at FreeBSD dot org


The patch may be correct for FreeBSD, but this is what it causes on  
Linux:

# cat sapi/cgi/tests/001.mem
==3077== Invalid read of size 1
==3077==at 0x4C23DB9: strncmp (mc_replace_strmem.c:314)
==3077==by 0x85C364D: unsetenv (in /lib64/libc-2.5.so)
==3077==by 0x4C24203: unsetenv (mc_replace_strmem.c:760)
==3077==by 0x7508BD: php_putenv_destructor (basic_functions.c: 
3826)

==3077==by 0x89901B: zend_hash_destroy (zend_hash.c:526)
==3077==by 0x7514CC: zm_deactivate_basic (basic_functions.c:4143)
==3077==by 0x892D02: module_registry_cleanup (zend_API.c:2119)
==3077==by 0x899602: zend_hash_apply (zend_hash.c:673)
==3077==by 0x888B77: zend_deactivate_modules (zend.c:874)
==3077==by 0x813040: php_request_shutdown (main.c:1497)
==3077==by 0x92C04A: main (php_cli.c:1320)
==3077==  Address 0x8ea3d08 is 0 bytes inside a block of size 18  
free'd

==3077==at 0x4C2292E: free (vg_replace_malloc.c:323)
==3077==by 0x864AD6: _efree (zend_alloc.c:2291)
==3077==by 0x7508AE: php_putenv_destructor (basic_functions.c: 
3823)

==3077==by 0x89901B: zend_hash_destroy (zend_hash.c:526)
==3077==by 0x7514CC: zm_deactivate_basic (basic_functions.c:4143)
==3077==by 0x892D02: module_registry_cleanup (zend_API.c:2119)
==3077==by 0x899602: zend_hash_apply (zend_hash.c:673)
==3077==by 0x888B77: zend_deactivate_modules (zend.c:874)
==3077==by 0x813040: php_request_shutdown (main.c:1497)
==3077==by 0x92C04A: main (php_cli.c:1320)
==3077==
==3077== Invalid read of size 1
==3077==at 0x4C23DC6: strncmp (mc_replace_strmem.c:314)
==3077==by 0x85C364D: unsetenv (in /lib64/libc-2.5.so)
==3077==by 0x4C24203: unsetenv (mc_replace_strmem.c:760)
==3077==by 0x7508BD: php_putenv_destructor (basic_functions.c: 
3826)

==3077==by 0x89901B: zend_hash_destroy (zend_hash.c:526)
==3077==by 0x7514CC: zm_deactivate_basic (basic_functions.c:4143)
==3077==by 0x892D02: module_registry_cleanup (zend_API.c:2119)
==3077==by 0x899602: zend_hash_apply (zend_hash.c:673)
==3077==by 0x888B77: zend_deactivate_modules (zend.c:874)
==3077==by 0x813040: php_request_shutdown (main.c:1497)
==3077==by 0x92C04A: main (php_cli.c:1320)
==3077==  Address 0x8ea3d08 is 0 bytes inside a block of size 18  
free'd

==3077==at 0x4C2292E: free (vg_replace_malloc.c:323)
==3077==by 0x864AD6: _efree (zend_alloc.c:2291)
==3077==by 0x7508AE: php_putenv_destructor (basic_functions.c: 
3823)

==3077==by 0x89901B: zend_hash_destroy (zend_hash.c:526)
==3077==by 0x7514CC: zm_deactivate_basic (basic_functions.c:4143)
==3077==by 0x892D02: module_registry_cleanup (zend_API.c:2119)
==3077==by 0x899602: zend_hash_apply (zend_hash.c:673)
==3077==by 0x888B77: zend_deactivate_modules (zend.c:874)
==3077==by 0x813040: php_request_shutdown (main.c:1497)
==3077==by 0x92C04A: main (php_cli.c:1320)
==3077==
==3077== Invalid read of size 1
==3077==at 0x4C23DB9: strncmp (mc_replace_strmem.c:314)
==3077==by 0x85C3750: __add_to_environ (in /lib64/libc-2.5.so)
==3077==by 0x85C34CD: putenv (in /lib64/libc-2.5.so)
==3077==by 0x4C24173: putenv (mc_replace_strmem.c:743)
==3077==by 0x75088C: php_putenv_destructor (basic_functions.c: 
3822)

==3077==by 0x89901B: zend_hash_destroy (zend_hash.c:526)
==3077==by 0x7514CC: zm_deactivate_basic (basic_functions.c:4143)
==3077==by 0x892D02: module_registry_cleanup (zend_API.c:2119)
==3077==by 0x899602: zend_hash_apply (zend_hash.c:673)
==3077==by 0x888B77: zend_deactivate_modules (zend.c:874)
==3077==by 0x813040: php_request_shutdown (main.c:1497)
==3077==by 0x92C04A: main (php_cli.c:1320)
==3077==  Address 0x8ea3d08 is 0 bytes inside a block of size 18  
free'd

==3077==at 0x4C2292E: free (vg_replace_malloc.c:323)
==3077==by 0x864AD6: _efree (zend_alloc.c:2291)
==3077==by 0x7508AE: php_putenv_destructor (basic_functions.c: 
3823)

==3077==by 0x89901B: zend_hash_destroy (zend_hash.c:526)
==3077==by 0x7514CC: zm_deactivate_basic (basic_functions.c:4143)
==3077==by 0x892D02: module_registry_cleanup (zend_API.c:2119)
==3077==by 0x899602: zend_hash_apply (zend_hash.c:673)
==3077==by 0x888B77: zend_deactivate_modules (zend.c:874)
==3077==by 0x813040: php_request_shutdown (main.c:1497)
==3077==by 0x92C04A: main (php_cli.c:1320)
==3077==
==3077== Invalid read of size 1
==3077==at 0x4C23DC6: strncmp (mc_replace_strmem.c:314)
==3077==by 0x85C3750: __add_to_environ (in /lib64/l

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

2008-05-07 Thread Hannes Magnusson
bjori   Wed May  7 20:04:05 2008 UTC

  Modified files:  (Branch: PHP_5_3)
/php-srcNEWS 
  Log:
  new ini_get_all() parameter
  
  
http://cvs.php.net/viewvc.cgi/php-src/NEWS?r1=1.2027.2.547.2.965.2.180&r2=1.2027.2.547.2.965.2.181&diff_format=u
Index: php-src/NEWS
diff -u php-src/NEWS:1.2027.2.547.2.965.2.180 
php-src/NEWS:1.2027.2.547.2.965.2.181
--- php-src/NEWS:1.2027.2.547.2.965.2.180   Wed May  7 16:01:37 2008
+++ php-src/NEWSWed May  7 20:04:05 2008
@@ -141,6 +141,8 @@
 mode of INI_SCANNER_NORMAL or INI_SCANNER_RAW. In raw mode option values
 and section values are treated as-is
   . Fixed get_cfg_var() to be able to return "array" ini options
+  . Added optional parameter to ini_get_all() to only retrieve the current
+value. (Hannes)
 - Improved and cleaned CGI code:
   . FastCGI is now always enabled and can not be disabled.
 See sapi/cgi/CHANGES for more details. (Dmitry)



-- 
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

2008-05-07 Thread Hannes Magnusson
bjori   Wed May  7 20:03:27 2008 UTC

  Modified files:  (Branch: PHP_5_2)
/php-srcNEWS 
  Log:
  BFN
  
  
http://cvs.php.net/viewvc.cgi/php-src/NEWS?r1=1.2027.2.547.2.1154&r2=1.2027.2.547.2.1155&diff_format=u
Index: php-src/NEWS
diff -u php-src/NEWS:1.2027.2.547.2.1154 php-src/NEWS:1.2027.2.547.2.1155
--- php-src/NEWS:1.2027.2.547.2.1154Wed May  7 15:08:42 2008
+++ php-src/NEWSWed May  7 20:03:26 2008
@@ -10,6 +10,8 @@
 - Fixed bug #44811 (Improve error message when creating a new SoapClient that 
   contains invalid data). (Markus Fischer, David C)
 - Fixed bug #44798 (Memory leak assigning value to attribute). (Ilia)
+- Fixed bug #44716 (Progress notifications incorrect). (Hannes)
+- Fixed bug #44712 (stream_context_set_params segfaults on invalid arguments). 
(Hannes)
 
 
 01 May 2008, PHP 5.2.6



-- 
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 streamsfuncs.c

2008-05-07 Thread Hannes Magnusson
bjori   Wed May  7 20:02:42 2008 UTC

  Modified files:  (Branch: PHP_5_2)
/php-src/ext/standard   streamsfuncs.c 
  Log:
  MFH: Fixed bug #44712 (stream_context_set_params segfaults on invalid
  arguments).
  
  
http://cvs.php.net/viewvc.cgi/php-src/ext/standard/streamsfuncs.c?r1=1.58.2.6.2.20&r2=1.58.2.6.2.21&diff_format=u
Index: php-src/ext/standard/streamsfuncs.c
diff -u php-src/ext/standard/streamsfuncs.c:1.58.2.6.2.20 
php-src/ext/standard/streamsfuncs.c:1.58.2.6.2.21
--- php-src/ext/standard/streamsfuncs.c:1.58.2.6.2.20   Sun May  4 21:19:18 2008
+++ php-src/ext/standard/streamsfuncs.c Wed May  7 20:02:42 2008
@@ -17,7 +17,7 @@
   +--+
 */
 
-/* $Id: streamsfuncs.c,v 1.58.2.6.2.20 2008/05/04 21:19:18 colder Exp $ */
+/* $Id: streamsfuncs.c,v 1.58.2.6.2.21 2008/05/07 20:02:42 bjori Exp $ */
 
 #include "php.h"
 #include "php_globals.h"
@@ -879,7 +879,7 @@
return ret;
 }
 
-static int parse_context_params(php_stream_context *context, zval *params)
+static int parse_context_params(php_stream_context *context, zval *params 
TSRMLS_DC)
 {
int ret = SUCCESS;
zval **tmp;
@@ -898,7 +898,11 @@
context->notifier->dtor = user_space_stream_notifier_dtor;
}
if (SUCCESS == zend_hash_find(Z_ARRVAL_P(params), "options", 
sizeof("options"), (void**)&tmp)) {
-   parse_context_options(context, *tmp);
+   if (Z_TYPE_PP(tmp) == IS_ARRAY) {
+   parse_context_options(context, *tmp);
+   } else {
+   php_error_docref(NULL TSRMLS_CC, E_WARNING, "Invalid 
stream/context parameter");
+   }
}

return ret;
@@ -1006,7 +1010,7 @@
RETURN_FALSE;
}
 
-   RETVAL_BOOL(parse_context_params(context, params) == SUCCESS);
+   RETVAL_BOOL(parse_context_params(context, params TSRMLS_CC) == SUCCESS);
 }
 /* }}} */
 



-- 
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/openssl xp_ssl.c

2008-05-07 Thread Hannes Magnusson
bjori   Wed May  7 20:01:56 2008 UTC

  Modified files:  (Branch: PHP_5_2)
/php-src/ext/opensslxp_ssl.c 
  Log:
  MFH: Fixed bug #44716 (Progress notifications incorrect)
  
  
http://cvs.php.net/viewvc.cgi/php-src/ext/openssl/xp_ssl.c?r1=1.22.2.3.2.11&r2=1.22.2.3.2.12&diff_format=u
Index: php-src/ext/openssl/xp_ssl.c
diff -u php-src/ext/openssl/xp_ssl.c:1.22.2.3.2.11 
php-src/ext/openssl/xp_ssl.c:1.22.2.3.2.12
--- php-src/ext/openssl/xp_ssl.c:1.22.2.3.2.11  Tue Apr  8 14:11:49 2008
+++ php-src/ext/openssl/xp_ssl.cWed May  7 20:01:56 2008
@@ -16,7 +16,7 @@
   +--+
 */
 
-/* $Id: xp_ssl.c,v 1.22.2.3.2.11 2008/04/08 14:11:49 jorton Exp $ */
+/* $Id: xp_ssl.c,v 1.22.2.3.2.12 2008/05/07 20:01:56 bjori Exp $ */
 
 #include "php.h"
 #include "ext/standard/file.h"
@@ -198,14 +198,13 @@
break;
}
} while(retry);
-   
+
+   if (didwrite > 0) {
+   php_stream_notify_progress_increment(stream->context, 
didwrite, 0);
+   }
} else {
didwrite = php_stream_socket_ops.write(stream, buf, count 
TSRMLS_CC);
}
-   
-   if (didwrite > 0) {
-   php_stream_notify_progress_increment(stream->context, didwrite, 
0);
-   }
 
if (didwrite < 0) {
didwrite = 0;
@@ -234,16 +233,16 @@
break;
}
} while (retry);
+
+   if (nr_bytes > 0) {
+   php_stream_notify_progress_increment(stream->context, 
nr_bytes, 0);
+   }
}
else
{
nr_bytes = php_stream_socket_ops.read(stream, buf, count 
TSRMLS_CC);
}
 
-   if (nr_bytes > 0) {
-   php_stream_notify_progress_increment(stream->context, nr_bytes, 
0);
-   }
-
if (nr_bytes < 0) {
nr_bytes = 0;
}



-- 
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) / NEWS

2008-05-07 Thread Antony Dovgal
tony2001Wed May  7 16:01:37 2008 UTC

  Modified files:  (Branch: PHP_5_3)
/php-srcNEWS 
  Log:
  MFH
  
  
http://cvs.php.net/viewvc.cgi/php-src/NEWS?r1=1.2027.2.547.2.965.2.179&r2=1.2027.2.547.2.965.2.180&diff_format=u
Index: php-src/NEWS
diff -u php-src/NEWS:1.2027.2.547.2.965.2.179 
php-src/NEWS:1.2027.2.547.2.965.2.180
--- php-src/NEWS:1.2027.2.547.2.965.2.179   Wed May  7 15:27:25 2008
+++ php-src/NEWSWed May  7 16:01:37 2008
@@ -264,8 +264,6 @@
   (Tony)
 - Fixed bug #27372 (parse error loading browscap.ini at apache startup).
   (Jani)
-- Fixed bug #44811 (Improve error message when creating a new SoapClient that 
-  contains invalid data). (Markus Fischer, David C)
 
 30 Aug 2007, PHP 5.2.4
 - Removed --enable-versioning configure option. (Jani)
@@ -3301,4 +3299,4 @@
 - Fixed bug #28699 (Reflection api bugs). (Marcus)
 - Fixed bug #28694 (ReflectionExtension::getFunctions() crashes PHP). (Marcus)
 - Fixed bug #28512 (Allocate enough space to store MSSQL data). (Frank)
-- Fixed strip_tags() to correctly handle '\0' characters. (Stefan)
\ No newline at end of file
+- Fixed strip_tags() to correctly handle '\0' characters. (Stefan)



-- 
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/oci8/tests bug37220.phpt bug43497.phpt bug43497_92.phpt bug44113.phpt bug44206.phpt connect_scope1.phpt connect_scope2.phpt connect_scope_try1.phpt connect_scope_t

2008-05-07 Thread Christopher Jones
sixdWed May  7 15:29:28 2008 UTC

  Added files: (Branch: PHP_5_2)
/php-src/ext/oci8/tests bug37220.phpt bug43497_92.phpt 
connect_scope1.phpt connect_scope2.phpt 
connect_scope_try1.phpt 
connect_scope_try2.phpt 
connect_scope_try3.phpt 
connect_scope_try4.phpt 
connect_scope_try5.phpt 
connect_scope_try6.phpt 
drcp_characterset.phpt 
drcp_conn_close1.phpt drcp_conn_close2.phpt 
drcp_connect1.phpt drcp_functions.inc 
drcp_newconnect.phpt drcp_pconn_close1.phpt 
drcp_pconn_close2.phpt drcp_privileged.phpt 
drcp_scope1.phpt drcp_scope2.phpt 
drcp_scope3.phpt drcp_scope4.phpt 
drcp_scope5.phpt pecl_bug10194_blob_64.phpt 
testping.phpt 

  Modified files:  
/php-src/ext/oci8/tests bug43497.phpt bug44113.phpt bug44206.phpt 
lob_042.phpt password.phpt password_2.phpt 
password_new.phpt password_old.phpt 
pecl_bug10194_blob.phpt 
  Log:
  MFH: new tests and test cleanup
  http://cvs.php.net/viewvc.cgi/php-src/ext/oci8/tests/bug43497.phpt?r1=1.1.2.1&r2=1.1.2.2&diff_format=u
Index: php-src/ext/oci8/tests/bug43497.phpt
diff -u php-src/ext/oci8/tests/bug43497.phpt:1.1.2.1 
php-src/ext/oci8/tests/bug43497.phpt:1.1.2.2
--- php-src/ext/oci8/tests/bug43497.phpt:1.1.2.1Tue Jan 15 20:42:13 2008
+++ php-src/ext/oci8/tests/bug43497.phptWed May  7 15:29:27 2008
@@ -1,7 +1,16 @@
 --TEST--
 Bug #43497 (OCI8 XML/getClobVal aka temporary LOBs leak UGA memory)
 --SKIPIF--
-
+ 9/', $phpinfo);
+if ($ov === 1) {
+   die ("skip expected output only valid for Oracle clients from 10g 
onwards");
+}
+?>
 --FILE--
 http://cvs.php.net/viewvc.cgi/php-src/ext/oci8/tests/bug44113.phpt?r1=1.1.2.1&r2=1.1.2.2&diff_format=u
Index: php-src/ext/oci8/tests/bug44113.phpt
diff -u php-src/ext/oci8/tests/bug44113.phpt:1.1.2.1 
php-src/ext/oci8/tests/bug44113.phpt:1.1.2.2
--- php-src/ext/oci8/tests/bug44113.phpt:1.1.2.1Fri Feb 15 23:05:19 2008
+++ php-src/ext/oci8/tests/bug44113.phptWed May  7 15:29:27 2008
@@ -5,7 +5,7 @@
 --FILE--
 http://cvs.php.net/viewvc.cgi/php-src/ext/oci8/tests/bug44206.phpt?r1=1.1.4.2&r2=1.1.4.3&diff_format=u
Index: php-src/ext/oci8/tests/bug44206.phpt
diff -u php-src/ext/oci8/tests/bug44206.phpt:1.1.4.2 
php-src/ext/oci8/tests/bug44206.phpt:1.1.4.3
--- php-src/ext/oci8/tests/bug44206.phpt:1.1.4.2Mon Feb 25 23:52:10 2008
+++ php-src/ext/oci8/tests/bug44206.phptWed May  7 15:29:27 2008
@@ -5,25 +5,27 @@
 --FILE--
 http://cvs.php.net/viewvc.cgi/php-src/ext/oci8/tests/lob_042.phpt?r1=1.1.2.1&r2=1.1.2.2&diff_format=u
Index: php-src/ext/oci8/tests/lob_042.phpt
diff -u php-src/ext/oci8/tests/lob_042.phpt:1.1.2.1 
php-src/ext/oci8/tests/lob_042.phpt:1.1.2.2
--- php-src/ext/oci8/tests/lob_042.phpt:1.1.2.1 Sat Feb 16 03:01:16 2008
+++ php-src/ext/oci8/tests/lob_042.phpt Wed May  7 15:29:27 2008
@@ -5,8 +5,6 @@
 --FILE--
 http://cvs.php.net/viewvc.cgi/php-src/ext/oci8/tests/password.phpt?r1=1.1.2.3&r2=1.1.2.3.2.1&diff_format=u
Index: php-src/ext/oci8/tests/password.phpt
diff -u php-src/ext/oci8/tests/password.phpt:1.1.2.3 
php-src/ext/oci8/tests/password.phpt:1.1.2.3.2.1
--- php-src/ext/oci8/tests/password.phpt:1.1.2.3Tue Dec  6 19:28:25 2005
+++ php-src/ext/oci8/tests/password.phptWed May  7 15:29:27 2008
@@ -1,24 +1,74 @@
 --TEST--
-oci_password_change()
+oci_password_change() for non-persistent connections
 --SKIPIF--
-
+
 --FILE--
 http://cvs.php.net/viewvc.cgi/php-src/ext/oci8/tests/password_2.phpt?r1=1.1.2.1&r2=1.1.2.2&diff_format=u
Index: php-src/ext/oci8/tests/password_2.phpt
diff -u php-src/ext/oci8/tests/password_2.phpt:1.1.2.1 
php-src/ext/oci8/tests/password_2.phpt:1.1.2.2
--- php-src/ext/oci8/tests/password_2.phpt:1.1.2.1  Fri Aug  3 01:55:15 2007
+++ php-src/ext/oci8/tests/password_2.phpt  Wed May  7 15:29:27 2008
@@ -4,6 +4,7 @@
 
 --FILE--
@@ -27,34 +28,19 @@
 // Connect (persistent) and change the password
 $c1 = oci_pconnect("testuser", "testuserpwd", $dbase);
 var_dump($c1);
-
-ob_start();
-var_dump($c1);
-$r1 = ob_get_clean();
-preg_match("/resource\(([0-9])\) of.*/", $r1, $matches);
-$rn1 = $matches[1]; /* resource number */
+$rn1 = (int)$c1;
 
 oci_password_change($c1, "testuser", "testuserpwd", "testuserpwd2");
 
 // Second connect should return a new resource because the hash string will be 
different from $c1
 $c2 = oci_pconnect("testuser", "testuserpwd2", $dbase);
 var_dump($c2);
-
-ob_

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

2008-05-07 Thread David Coallier
davidc  Wed May  7 15:27:25 2008 UTC

  Modified files:  (Branch: PHP_5_3)
/php-srcNEWS 
  Log:
  - Added NEWS item for fixation of bug 44811
  
  
http://cvs.php.net/viewvc.cgi/php-src/NEWS?r1=1.2027.2.547.2.965.2.178&r2=1.2027.2.547.2.965.2.179&diff_format=u
Index: php-src/NEWS
diff -u php-src/NEWS:1.2027.2.547.2.965.2.178 
php-src/NEWS:1.2027.2.547.2.965.2.179
--- php-src/NEWS:1.2027.2.547.2.965.2.178   Wed May  7 12:04:37 2008
+++ php-src/NEWSWed May  7 15:27:25 2008
@@ -264,6 +264,8 @@
   (Tony)
 - Fixed bug #27372 (parse error loading browscap.ini at apache startup).
   (Jani)
+- Fixed bug #44811 (Improve error message when creating a new SoapClient that 
+  contains invalid data). (Markus Fischer, David C)
 
 30 Aug 2007, PHP 5.2.4
 - Removed --enable-versioning configure option. (Jani)



-- 
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/soap/tests/bugs 44811.phpt bug44811.phpt

2008-05-07 Thread Antony Dovgal
tony2001Wed May  7 15:23:31 2008 UTC

  Added files: (Branch: PHP_5_3)
/php-src/ext/soap/tests/bugsbug44811.phpt 

  Removed files:   
/php-src/ext/soap/tests/bugs44811.phpt 
  Log:
  rename the test
  
  

http://cvs.php.net/viewvc.cgi/php-src/ext/soap/tests/bugs/bug44811.phpt?view=markup&rev=1.1
Index: php-src/ext/soap/tests/bugs/bug44811.phpt
+++ php-src/ext/soap/tests/bugs/bug44811.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_2) /ext/soap/tests/bugs bug44811.phpt

2008-05-07 Thread Antony Dovgal
tony2001Wed May  7 15:23:11 2008 UTC

  Modified files:  (Branch: PHP_5_2)
/php-src/ext/soap/tests/bugsbug44811.phpt 
  Log:
  fix test title
  
  
http://cvs.php.net/viewvc.cgi/php-src/ext/soap/tests/bugs/bug44811.phpt?r1=1.1.2.1&r2=1.1.2.2&diff_format=u
Index: php-src/ext/soap/tests/bugs/bug44811.phpt
diff -u php-src/ext/soap/tests/bugs/bug44811.phpt:1.1.2.1 
php-src/ext/soap/tests/bugs/bug44811.phpt:1.1.2.2
--- php-src/ext/soap/tests/bugs/bug44811.phpt:1.1.2.1   Wed May  7 14:56:36 2008
+++ php-src/ext/soap/tests/bugs/bug44811.phpt   Wed May  7 15:23:11 2008
@@ -1,6 +1,5 @@
 --TEST--
-Bug #44811 (Improve error messages when creating new SoapClient
-which contains invalid data)
+Bug #44811 (Improve error messages when creating new SoapClient which contains 
invalid data)
 --SKIPIF--
 
 --INI--



-- 
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/soap php_sdl.c

2008-05-07 Thread David Coallier
davidc  Wed May  7 15:23:11 2008 UTC

  Modified files:  (Branch: PHP_5_3)
/php-src/ext/soap   php_sdl.c 
  Log:
  - Fixed bug #44811 (Improve error message when creating a new SoapClient that 
contains invalid data)
  
  
http://cvs.php.net/viewvc.cgi/php-src/ext/soap/php_sdl.c?r1=1.88.2.12.2.9.2.2&r2=1.88.2.12.2.9.2.3&diff_format=u
Index: php-src/ext/soap/php_sdl.c
diff -u php-src/ext/soap/php_sdl.c:1.88.2.12.2.9.2.2 
php-src/ext/soap/php_sdl.c:1.88.2.12.2.9.2.3
--- php-src/ext/soap/php_sdl.c:1.88.2.12.2.9.2.2Mon Dec 31 07:17:13 2007
+++ php-src/ext/soap/php_sdl.c  Wed May  7 15:23:10 2008
@@ -17,7 +17,7 @@
   |  Dmitry Stogov <[EMAIL PROTECTED]> |
   +--+
 */
-/* $Id: php_sdl.c,v 1.88.2.12.2.9.2.2 2007/12/31 07:17:13 sebastian Exp $ */
+/* $Id: php_sdl.c,v 1.88.2.12.2.9.2.3 2008/05/07 15:23:10 davidc Exp $ */
 
 #include "php_soap.h"
 #include "ext/libxml/php_libxml.h"
@@ -240,7 +240,13 @@
wsdl = soap_xmlParseFile(struri TSRMLS_CC);

if (!wsdl) {
-   soap_error1(E_ERROR, "Parsing WSDL: Couldn't load from '%s'", 
struri);
+   xmlErrorPtr xmlErrorPtr = xmlGetLastError();
+
+   if (xmlErrorPtr) {
+   soap_error2(E_ERROR, "Parsing WSDL: Couldn't load from 
'%s' : %s", struri, xmlErrorPtr->message);
+   } else {
+   soap_error1(E_ERROR, "Parsing WSDL: Couldn't load from 
'%s'", struri);
+   }
}
 
zend_hash_add(&ctx->docs, struri, strlen(struri)+1, (void**)&wsdl, 
sizeof(xmlDocPtr), NULL);



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



[PHP-CVS] cvs: php-src / NEWS

2008-05-07 Thread Antony Dovgal
tony2001Wed May  7 15:51:35 2008 UTC

  Modified files:  
/php-srcNEWS 
  Log:
  no need to add this entry - it's in 5_2 already
  
  
http://cvs.php.net/viewvc.cgi/php-src/NEWS?r1=1.2161&r2=1.2162&diff_format=u
Index: php-src/NEWS
diff -u php-src/NEWS:1.2161 php-src/NEWS:1.2162
--- php-src/NEWS:1.2161 Wed May  7 15:47:04 2008
+++ php-src/NEWSWed May  7 15:51:34 2008
@@ -51,5 +51,3 @@
 - Added ext/hash support to ext/session's ID generator. (Sara)
 
 - Fixed bug #40325 (Vary: header missing in gzip output handlers). (Mike)
-- Fixed bug #44811 (Improve error message when creating a new SoapClient that 
-  contains invalid data). (Markus Fischer, David C)



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



[PHP-CVS] cvs: php-src / NEWS

2008-05-07 Thread David Coallier
davidc  Wed May  7 15:47:04 2008 UTC

  Modified files:  
/php-srcNEWS 
  Log:
  - Added news item to the NEWS (Fixed bug 44811)
  
  
http://cvs.php.net/viewvc.cgi/php-src/NEWS?r1=1.2160&r2=1.2161&diff_format=u
Index: php-src/NEWS
diff -u php-src/NEWS:1.2160 php-src/NEWS:1.2161
--- php-src/NEWS:1.2160 Fri Mar 28 23:59:37 2008
+++ php-src/NEWSWed May  7 15:47:04 2008
@@ -51,4 +51,5 @@
 - Added ext/hash support to ext/session's ID generator. (Sara)
 
 - Fixed bug #40325 (Vary: header missing in gzip output handlers). (Mike)
-
+- Fixed bug #44811 (Improve error message when creating a new SoapClient that 
+  contains invalid data). (Markus Fischer, David C)



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



[PHP-CVS] cvs: php-src /ext/soap/tests/bugs bug44811.phpt

2008-05-07 Thread David Coallier
davidc  Wed May  7 15:45:56 2008 UTC

  Modified files:  
/php-src/ext/soap/tests/bugsbug44811.phpt 
  Log:
  - Test for bug #44811
  
  
http://cvs.php.net/viewvc.cgi/php-src/ext/soap/tests/bugs/bug44811.phpt?r1=1.1&r2=1.2&diff_format=u
Index: php-src/ext/soap/tests/bugs/bug44811.phpt
diff -u /dev/null php-src/ext/soap/tests/bugs/bug44811.phpt:1.2
--- /dev/null   Wed May  7 15:45:56 2008
+++ php-src/ext/soap/tests/bugs/bug44811.phpt   Wed May  7 15:45:56 2008
@@ -0,0 +1,20 @@
+--TEST--
+Bug #44811 (Improve error messages when creating new SoapClient
+which contains invalid data)
+--SKIPIF--
+
+--INI--
+soap.wsdl_cache_enabled=0
+--FILE--
+http://slashdot.org');
+} catch (SoapFault $e) {
+echo $e->getMessage() . PHP_EOL;
+}
+die('ok');
+?>
+--EXPECT--
+SOAP-ERROR: Parsing WSDL: Couldn't load from 'http://slashdot.org' : Premature 
end of data in tag html line 3
+
+ok



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



[PHP-CVS] cvs: php-src /ext/soap php_sdl.c

2008-05-07 Thread David Coallier
davidc  Wed May  7 15:45:02 2008 UTC

  Modified files:  
/php-src/ext/soap   php_sdl.c 
  Log:
  - Fixed bug #44811 (Improve error message when creating new SoapClient
  that contains invalid data)
  
  
http://cvs.php.net/viewvc.cgi/php-src/ext/soap/php_sdl.c?r1=1.111&r2=1.112&diff_format=u
Index: php-src/ext/soap/php_sdl.c
diff -u php-src/ext/soap/php_sdl.c:1.111 php-src/ext/soap/php_sdl.c:1.112
--- php-src/ext/soap/php_sdl.c:1.111Mon Dec 31 07:12:14 2007
+++ php-src/ext/soap/php_sdl.c  Wed May  7 15:45:02 2008
@@ -17,7 +17,7 @@
   |  Dmitry Stogov <[EMAIL PROTECTED]> |
   +--+
 */
-/* $Id: php_sdl.c,v 1.111 2007/12/31 07:12:14 sebastian Exp $ */
+/* $Id: php_sdl.c,v 1.112 2008/05/07 15:45:02 davidc Exp $ */
 
 #include "php_soap.h"
 #include "ext/libxml/php_libxml.h"
@@ -240,7 +240,12 @@
wsdl = soap_xmlParseFile(struri TSRMLS_CC);

if (!wsdl) {
-   soap_error1(E_ERROR, "Parsing WSDL: Couldn't load from '%s'", 
struri);
+   xmlErrorPtr xmlErrorPtr = xmlGetLastError();
+   if (xmlErrorPtr) {
+   soap_error2(E_ERROR, "Parsing WSDL: Couldn't load from 
'%s' : %s", struri, xmlErrorPtr->message);
+   } else {
+   soap_error1(E_ERROR, "Parsing WSDL: Couldn't load from 
'%s'", struri);
+   }
}
 
zend_hash_add(&ctx->docs, struri, strlen(struri)+1, (void**)&wsdl, 
sizeof(xmlDocPtr), NULL);



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



[PHP-CVS] cvs: php-src /ext/mysqlnd mysqlnd.c mysqlnd.h mysqlnd_enum_n_def.h mysqlnd_libmysql_compat.h mysqlnd_result.c mysqlnd_statistics.c php_mysqlnd.c

2008-05-07 Thread Andrey Hristov
andrey  Wed May  7 15:16:27 2008 UTC

  Modified files:  
/php-src/ext/mysqlndmysqlnd.c mysqlnd.h mysqlnd_enum_n_def.h 
mysqlnd_libmysql_compat.h mysqlnd_result.c 
mysqlnd_statistics.c php_mysqlnd.c 
  Log:
  Update mysqlnd - new ini variable
  
  http://cvs.php.net/viewvc.cgi/php-src/ext/mysqlnd/mysqlnd.c?r1=1.22&r2=1.23&diff_format=u
Index: php-src/ext/mysqlnd/mysqlnd.c
diff -u php-src/ext/mysqlnd/mysqlnd.c:1.22 php-src/ext/mysqlnd/mysqlnd.c:1.23
--- php-src/ext/mysqlnd/mysqlnd.c:1.22  Thu Apr 24 14:04:58 2008
+++ php-src/ext/mysqlnd/mysqlnd.c   Wed May  7 15:16:27 2008
@@ -18,7 +18,7 @@
   +--+
 */
 
-/* $Id: mysqlnd.c,v 1.22 2008/04/24 14:04:58 andrey Exp $ */
+/* $Id: mysqlnd.c,v 1.23 2008/05/07 15:16:27 andrey Exp $ */
 #include "php.h"
 #include "mysqlnd.h"
 #include "mysqlnd_wireprotocol.h"
@@ -1390,7 +1390,7 @@
 }
 /* }}} */
 
-
+#if !defined(MYSQLND_USE_OPTIMISATIONS) || MYSQLND_USE_OPTIMISATIONS == 0
 /* {{{ mysqlnd_get_client_info */
 PHPAPI const char * mysqlnd_get_client_info()
 {
@@ -1405,7 +1405,7 @@
return MYSQLND_VERSION_ID;
 }
 /* }}} */
-
+#endif
 
 /* {{{ mysqlnd_conn::get_server_info */
 static const char *
http://cvs.php.net/viewvc.cgi/php-src/ext/mysqlnd/mysqlnd.h?r1=1.16&r2=1.17&diff_format=u
Index: php-src/ext/mysqlnd/mysqlnd.h
diff -u php-src/ext/mysqlnd/mysqlnd.h:1.16 php-src/ext/mysqlnd/mysqlnd.h:1.17
--- php-src/ext/mysqlnd/mysqlnd.h:1.16  Thu Apr 24 14:04:58 2008
+++ php-src/ext/mysqlnd/mysqlnd.h   Wed May  7 15:16:27 2008
@@ -18,13 +18,13 @@
   +--+
 */
 
-/* $Id: mysqlnd.h,v 1.16 2008/04/24 14:04:58 andrey Exp $ */
+/* $Id: mysqlnd.h,v 1.17 2008/05/07 15:16:27 andrey Exp $ */
 
 #ifndef MYSQLND_H
 #define MYSQLND_H
 
-#define MYSQLND_VERSION "mysqlnd 5.0.3-dev - 080129 - $Revision: 1.16 $"
-#define MYSQLND_VERSION_ID 50002
+#define MYSQLND_VERSION "mysqlnd 5.0.4-dev - 080501 - $Revision: 1.17 $"
+#define MYSQLND_VERSION_ID 50004
 
 /* This forces inlining of some accessor functions */
 #define MYSQLND_USE_OPTIMISATIONS 0
@@ -138,13 +138,13 @@
 #define mysqlnd_get_proto_info(conn)   (conn)->protocol_version
 #define mysqlnd_thread_id(conn)(conn)->thread_id
 
-#define mysqlnd_num_rows(result)   ((result)->data? 
(result)->data->row_count:0)
+#define mysqlnd_num_rows(result)   ((result)->stored_data? 
(result)->stored_data->row_count:0)
 #define mysqlnd_num_fields(result) (result)->field_count
 
 #define mysqlnd_fetch_lengths(result)  ((result)->m.fetch_lengths? 
(result)->m.fetch_lengths((result)):NULL)
 
 #define mysqlnd_field_seek(result, ofs)
(result)->m.seek_field((result), (ofs))
-#define mysqlnd_field_tell(result) (result)->meta? 
(result)->meta->current_field:0)
+#define mysqlnd_field_tell(result) 
((result)->meta? (result)->meta->current_field:0)
 #define mysqlnd_fetch_field(result)
(result)->m.fetch_field((result) TSRMLS_CC)
 #define mysqlnd_fetch_field_direct(result,fnr) ((result)->meta? 
&((result)->meta->fields[(fnr)]):NULL)
 #define mysqlnd_fetch_fields(result)   ((result)->meta? 
(result)->meta->fields: NULL)
@@ -358,6 +358,7 @@
MYSQLND_DEBUG   *dbg;   /* The DBG object */
longnet_cmd_buffer_size;
longnet_read_buffer_size;
+   longlog_mask;
 #ifdef MYSQLND_THREADED
THREAD_Tthread_id;
 #endif
http://cvs.php.net/viewvc.cgi/php-src/ext/mysqlnd/mysqlnd_enum_n_def.h?r1=1.7&r2=1.8&diff_format=u
Index: php-src/ext/mysqlnd/mysqlnd_enum_n_def.h
diff -u php-src/ext/mysqlnd/mysqlnd_enum_n_def.h:1.7 
php-src/ext/mysqlnd/mysqlnd_enum_n_def.h:1.8
--- php-src/ext/mysqlnd/mysqlnd_enum_n_def.h:1.7Thu Apr 24 14:04:58 2008
+++ php-src/ext/mysqlnd/mysqlnd_enum_n_def.hWed May  7 15:16:27 2008
@@ -18,7 +18,7 @@
   +--+
 */
 
-/* $Id: mysqlnd_enum_n_def.h,v 1.7 2008/04/24 14:04:58 andrey Exp $ */
+/* $Id: mysqlnd_enum_n_def.h,v 1.8 2008/05/07 15:16:27 andrey Exp $ */
 #ifndef MYSQLND_ENUM_N_DEF_H
 #define MYSQLND_ENUM_N_DEF_H
 
@@ -31,8 +31,8 @@
 #define SERVER_STATUS_IN_TRANS 1   /* 
Transaction has started */
 #define SERVER_STATUS_AUTOCOMMIT   2   /* 
Server in auto_commit mode */
 #define SERVER_MORE_RESULTS_EXISTS 8   /* 
Multi query - next query exists */
-#define MYSQLND_SERVER_QUERY_NO_GOOD_INDEX_USED16
-#define MYSQLND_SERVER_QUERY_NO_INDEX_USED 32
+#define SERVER_QUERY_NO_GOOD_INDEX_USED16
+#define SERVER_QUERY_NO_INDEX_USED 

[PHP-CVS] cvs: php-src(PHP_5_3) /ext/mysqlnd mysqlnd.c mysqlnd.h mysqlnd_enum_n_def.h mysqlnd_libmysql_compat.h mysqlnd_palloc.c mysqlnd_result.c mysqlnd_statistics.c php_mysqlnd.c

2008-05-07 Thread Andrey Hristov
andrey  Wed May  7 15:14:26 2008 UTC

  Modified files:  (Branch: PHP_5_3)
/php-src/ext/mysqlndmysqlnd.c mysqlnd.h mysqlnd_enum_n_def.h 
mysqlnd_libmysql_compat.h mysqlnd_palloc.c 
mysqlnd_result.c mysqlnd_statistics.c 
php_mysqlnd.c 
  Log:
  Update mysqlnd
  
  http://cvs.php.net/viewvc.cgi/php-src/ext/mysqlnd/mysqlnd.c?r1=1.5.2.19&r2=1.5.2.20&diff_format=u
Index: php-src/ext/mysqlnd/mysqlnd.c
diff -u php-src/ext/mysqlnd/mysqlnd.c:1.5.2.19 
php-src/ext/mysqlnd/mysqlnd.c:1.5.2.20
--- php-src/ext/mysqlnd/mysqlnd.c:1.5.2.19  Thu Apr 24 14:22:19 2008
+++ php-src/ext/mysqlnd/mysqlnd.c   Wed May  7 15:14:26 2008
@@ -18,7 +18,7 @@
   +--+
 */
 
-/* $Id: mysqlnd.c,v 1.5.2.19 2008/04/24 14:22:19 andrey Exp $ */
+/* $Id: mysqlnd.c,v 1.5.2.20 2008/05/07 15:14:26 andrey Exp $ */
 #include "php.h"
 #include "mysqlnd.h"
 #include "mysqlnd_wireprotocol.h"
@@ -1390,7 +1390,7 @@
 }
 /* }}} */
 
-
+#if !defined(MYSQLND_USE_OPTIMISATIONS) || MYSQLND_USE_OPTIMISATIONS == 0
 /* {{{ mysqlnd_get_client_info */
 PHPAPI const char * mysqlnd_get_client_info()
 {
@@ -1405,7 +1405,7 @@
return MYSQLND_VERSION_ID;
 }
 /* }}} */
-
+#endif
 
 /* {{{ mysqlnd_conn::get_server_info */
 static const char *
http://cvs.php.net/viewvc.cgi/php-src/ext/mysqlnd/mysqlnd.h?r1=1.3.2.14&r2=1.3.2.15&diff_format=u
Index: php-src/ext/mysqlnd/mysqlnd.h
diff -u php-src/ext/mysqlnd/mysqlnd.h:1.3.2.14 
php-src/ext/mysqlnd/mysqlnd.h:1.3.2.15
--- php-src/ext/mysqlnd/mysqlnd.h:1.3.2.14  Thu Apr 24 14:22:19 2008
+++ php-src/ext/mysqlnd/mysqlnd.h   Wed May  7 15:14:26 2008
@@ -18,13 +18,13 @@
   +--+
 */
 
-/* $Id: mysqlnd.h,v 1.3.2.14 2008/04/24 14:22:19 andrey Exp $ */
+/* $Id: mysqlnd.h,v 1.3.2.15 2008/05/07 15:14:26 andrey Exp $ */
 
 #ifndef MYSQLND_H
 #define MYSQLND_H
 
-#define MYSQLND_VERSION "mysqlnd 5.0.3-dev - 080129 - $Revision: 1.3.2.14 $"
-#define MYSQLND_VERSION_ID 50002
+#define MYSQLND_VERSION "mysqlnd 5.0.4-dev - 080501 - $Revision: 1.3.2.15 $"
+#define MYSQLND_VERSION_ID 50004
 
 /* This forces inlining of some accessor functions */
 #define MYSQLND_USE_OPTIMISATIONS 0
@@ -138,13 +138,13 @@
 #define mysqlnd_get_proto_info(conn)   (conn)->protocol_version
 #define mysqlnd_thread_id(conn)(conn)->thread_id
 
-#define mysqlnd_num_rows(result)   ((result)->data? 
(result)->data->row_count:0)
+#define mysqlnd_num_rows(result)   ((result)->stored_data? 
(result)->stored_data->row_count:0)
 #define mysqlnd_num_fields(result) (result)->field_count
 
 #define mysqlnd_fetch_lengths(result)  ((result)->m.fetch_lengths? 
(result)->m.fetch_lengths((result)):NULL)
 
 #define mysqlnd_field_seek(result, ofs)
(result)->m.seek_field((result), (ofs))
-#define mysqlnd_field_tell(result) (result)->meta? 
(result)->meta->current_field:0)
+#define mysqlnd_field_tell(result) 
((result)->meta? (result)->meta->current_field:0)
 #define mysqlnd_fetch_field(result)
(result)->m.fetch_field((result) TSRMLS_CC)
 #define mysqlnd_fetch_field_direct(result,fnr) ((result)->meta? 
&((result)->meta->fields[(fnr)]):NULL)
 #define mysqlnd_fetch_fields(result)   ((result)->meta? 
(result)->meta->fields: NULL)
@@ -358,6 +358,7 @@
MYSQLND_DEBUG   *dbg;   /* The DBG object */
longnet_cmd_buffer_size;
longnet_read_buffer_size;
+   longlog_mask;
 #ifdef MYSQLND_THREADED
THREAD_Tthread_id;
 #endif
http://cvs.php.net/viewvc.cgi/php-src/ext/mysqlnd/mysqlnd_enum_n_def.h?r1=1.2.2.8&r2=1.2.2.9&diff_format=u
Index: php-src/ext/mysqlnd/mysqlnd_enum_n_def.h
diff -u php-src/ext/mysqlnd/mysqlnd_enum_n_def.h:1.2.2.8 
php-src/ext/mysqlnd/mysqlnd_enum_n_def.h:1.2.2.9
--- php-src/ext/mysqlnd/mysqlnd_enum_n_def.h:1.2.2.8Thu Apr 24 14:22:19 2008
+++ php-src/ext/mysqlnd/mysqlnd_enum_n_def.hWed May  7 15:14:26 2008
@@ -18,7 +18,7 @@
   +--+
 */
 
-/* $Id: mysqlnd_enum_n_def.h,v 1.2.2.8 2008/04/24 14:22:19 andrey Exp $ */
+/* $Id: mysqlnd_enum_n_def.h,v 1.2.2.9 2008/05/07 15:14:26 andrey Exp $ */
 #ifndef MYSQLND_ENUM_N_DEF_H
 #define MYSQLND_ENUM_N_DEF_H
 
@@ -31,8 +31,8 @@
 #define SERVER_STATUS_IN_TRANS 1   /* 
Transaction has started */
 #define SERVER_STATUS_AUTOCOMMIT   2   /* 
Server in auto_commit mode */
 #define SERVER_MORE_RESULTS_EXISTS 8   /* 
Multi query - next query exists */
-#define MYSQLND_SERVER_QUERY_NO_GOOD_INDEX_USED16
-#define MYS

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

2008-05-07 Thread David Coallier
davidc  Wed May  7 15:14:16 2008 UTC

  Added files: (Branch: PHP_5_3)
/php-src/ext/soap/tests/bugs44811.phpt 
  Log:
  - Bug #44811 (Improved error message for creating invalid new SoapClient)
  
  

http://cvs.php.net/viewvc.cgi/php-src/ext/soap/tests/bugs/44811.phpt?view=markup&rev=1.1
Index: php-src/ext/soap/tests/bugs/44811.phpt
+++ php-src/ext/soap/tests/bugs/44811.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_2) / NEWS

2008-05-07 Thread Antony Dovgal
tony2001Wed May  7 15:08:43 2008 UTC

  Modified files:  (Branch: PHP_5_2)
/php-srcNEWS 
  Log:
  reorder
  
  
http://cvs.php.net/viewvc.cgi/php-src/NEWS?r1=1.2027.2.547.2.1153&r2=1.2027.2.547.2.1154&diff_format=u
Index: php-src/NEWS
diff -u php-src/NEWS:1.2027.2.547.2.1153 php-src/NEWS:1.2027.2.547.2.1154
--- php-src/NEWS:1.2027.2.547.2.1153Wed May  7 15:03:17 2008
+++ php-src/NEWSWed May  7 15:08:42 2008
@@ -7,9 +7,9 @@
   as function parameter. (Rob)
 - Fixed bug #44836 (putenv() crashes, avoid direct reference of environ in
   POSIX systems). (Ilia, delphij at FreeBSD dot org)
+- Fixed bug #44811 (Improve error message when creating a new SoapClient that 
+  contains invalid data). (Markus Fischer, David C)
 - Fixed bug #44798 (Memory leak assigning value to attribute). (Ilia)
-- Fixed bug #44811 (Improve error message when creating a new 
-  SoapClient that contains invalid data. (Markus Fischer, David C)
 
 
 01 May 2008, PHP 5.2.6



-- 
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

2008-05-07 Thread David Coallier
davidc  Wed May  7 15:03:17 2008 UTC

  Modified files:  (Branch: PHP_5_2)
/php-srcNEWS 
  Log:
  - Added NEWS item for fixation of bug 44811
  
  
http://cvs.php.net/viewvc.cgi/php-src/NEWS?r1=1.2027.2.547.2.1152&r2=1.2027.2.547.2.1153&diff_format=u
Index: php-src/NEWS
diff -u php-src/NEWS:1.2027.2.547.2.1152 php-src/NEWS:1.2027.2.547.2.1153
--- php-src/NEWS:1.2027.2.547.2.1152Tue May  6 18:03:52 2008
+++ php-src/NEWSWed May  7 15:03:17 2008
@@ -8,6 +8,8 @@
 - Fixed bug #44836 (putenv() crashes, avoid direct reference of environ in
   POSIX systems). (Ilia, delphij at FreeBSD dot org)
 - Fixed bug #44798 (Memory leak assigning value to attribute). (Ilia)
+- Fixed bug #44811 (Improve error message when creating a new 
+  SoapClient that contains invalid data. (Markus Fischer, David C)
 
 
 01 May 2008, PHP 5.2.6



-- 
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 php_sdl.c

2008-05-07 Thread David Coallier
davidc  Wed May  7 14:57:56 2008 UTC

  Modified files:  (Branch: PHP_5_2)
/php-src/ext/soap   php_sdl.c 
  Log:
  - Fixed Bug #44811: Improved error message when creating a new
  SoapClient has invalid data.
  
  
http://cvs.php.net/viewvc.cgi/php-src/ext/soap/php_sdl.c?r1=1.88.2.12.2.10&r2=1.88.2.12.2.11&diff_format=u
Index: php-src/ext/soap/php_sdl.c
diff -u php-src/ext/soap/php_sdl.c:1.88.2.12.2.10 
php-src/ext/soap/php_sdl.c:1.88.2.12.2.11
--- php-src/ext/soap/php_sdl.c:1.88.2.12.2.10   Mon Dec 31 07:20:11 2007
+++ php-src/ext/soap/php_sdl.c  Wed May  7 14:57:56 2008
@@ -17,7 +17,7 @@
   |  Dmitry Stogov <[EMAIL PROTECTED]> |
   +--+
 */
-/* $Id: php_sdl.c,v 1.88.2.12.2.10 2007/12/31 07:20:11 sebastian Exp $ */
+/* $Id: php_sdl.c,v 1.88.2.12.2.11 2008/05/07 14:57:56 davidc Exp $ */
 
 #include "php_soap.h"
 #include "ext/libxml/php_libxml.h"
@@ -240,7 +240,12 @@
wsdl = soap_xmlParseFile(struri TSRMLS_CC);

if (!wsdl) {
-   soap_error1(E_ERROR, "Parsing WSDL: Couldn't load from '%s'", 
struri);
+   xmlErrorPtr xmlErrorPtr = xmlGetLastError();
+   if (xmlErrorPtr) {
+   soap_error2(E_ERROR, "Parsing WSDL: Couldn't load from 
'%s' : %s", struri, xmlErrorPtr->message);
+   } else {
+   soap_error1(E_ERROR, "Parsing WSDL: Couldn't load from 
'%s'", struri);
+   }
}
 
zend_hash_add(&ctx->docs, struri, strlen(struri)+1, (void**)&wsdl, 
sizeof(xmlDocPtr), NULL);



-- 
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 bug44811.phpt

2008-05-07 Thread David Coallier
davidc  Wed May  7 14:56:36 2008 UTC

  Added files: (Branch: PHP_5_2)
/php-src/ext/soap/tests/bugsbug44811.phpt 
  Log:
  - Test for bug #44811 (Improve error message when new SoapClient has invalid 
data)
  
  

http://cvs.php.net/viewvc.cgi/php-src/ext/soap/tests/bugs/bug44811.phpt?view=markup&rev=1.1
Index: php-src/ext/soap/tests/bugs/bug44811.phpt
+++ php-src/ext/soap/tests/bugs/bug44811.phpt



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



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

2008-05-07 Thread Ilia Alshanetsky

I'll take a look, I wonder why it would cause a problem on Linux...


On 7-May-08, at 4:42 AM, Antony Dovgal wrote:


On 06.05.2008 22:01, Ilia Alshanetsky wrote:

iliaa   Tue May  6 18:01:36 2008 UTC
 Modified files:  (Branch: PHP_5_3)
   /php-src/ext/standardbasic_functions.c   Log:
 Fixed bug #44836 (putenv() crashes, avoid direct reference of  
environ in

 POSIX systems)
   # Original patch by delphij at FreeBSD dot org


The patch may be correct for FreeBSD, but this is what it causes on  
Linux:

# cat sapi/cgi/tests/001.mem
==3077== Invalid read of size 1
==3077==at 0x4C23DB9: strncmp (mc_replace_strmem.c:314)
==3077==by 0x85C364D: unsetenv (in /lib64/libc-2.5.so)
==3077==by 0x4C24203: unsetenv (mc_replace_strmem.c:760)
==3077==by 0x7508BD: php_putenv_destructor (basic_functions.c: 
3826)

==3077==by 0x89901B: zend_hash_destroy (zend_hash.c:526)
==3077==by 0x7514CC: zm_deactivate_basic (basic_functions.c:4143)
==3077==by 0x892D02: module_registry_cleanup (zend_API.c:2119)
==3077==by 0x899602: zend_hash_apply (zend_hash.c:673)
==3077==by 0x888B77: zend_deactivate_modules (zend.c:874)
==3077==by 0x813040: php_request_shutdown (main.c:1497)
==3077==by 0x92C04A: main (php_cli.c:1320)
==3077==  Address 0x8ea3d08 is 0 bytes inside a block of size 18  
free'd

==3077==at 0x4C2292E: free (vg_replace_malloc.c:323)
==3077==by 0x864AD6: _efree (zend_alloc.c:2291)
==3077==by 0x7508AE: php_putenv_destructor (basic_functions.c: 
3823)

==3077==by 0x89901B: zend_hash_destroy (zend_hash.c:526)
==3077==by 0x7514CC: zm_deactivate_basic (basic_functions.c:4143)
==3077==by 0x892D02: module_registry_cleanup (zend_API.c:2119)
==3077==by 0x899602: zend_hash_apply (zend_hash.c:673)
==3077==by 0x888B77: zend_deactivate_modules (zend.c:874)
==3077==by 0x813040: php_request_shutdown (main.c:1497)
==3077==by 0x92C04A: main (php_cli.c:1320)
==3077==
==3077== Invalid read of size 1
==3077==at 0x4C23DC6: strncmp (mc_replace_strmem.c:314)
==3077==by 0x85C364D: unsetenv (in /lib64/libc-2.5.so)
==3077==by 0x4C24203: unsetenv (mc_replace_strmem.c:760)
==3077==by 0x7508BD: php_putenv_destructor (basic_functions.c: 
3826)

==3077==by 0x89901B: zend_hash_destroy (zend_hash.c:526)
==3077==by 0x7514CC: zm_deactivate_basic (basic_functions.c:4143)
==3077==by 0x892D02: module_registry_cleanup (zend_API.c:2119)
==3077==by 0x899602: zend_hash_apply (zend_hash.c:673)
==3077==by 0x888B77: zend_deactivate_modules (zend.c:874)
==3077==by 0x813040: php_request_shutdown (main.c:1497)
==3077==by 0x92C04A: main (php_cli.c:1320)
==3077==  Address 0x8ea3d08 is 0 bytes inside a block of size 18  
free'd

==3077==at 0x4C2292E: free (vg_replace_malloc.c:323)
==3077==by 0x864AD6: _efree (zend_alloc.c:2291)
==3077==by 0x7508AE: php_putenv_destructor (basic_functions.c: 
3823)

==3077==by 0x89901B: zend_hash_destroy (zend_hash.c:526)
==3077==by 0x7514CC: zm_deactivate_basic (basic_functions.c:4143)
==3077==by 0x892D02: module_registry_cleanup (zend_API.c:2119)
==3077==by 0x899602: zend_hash_apply (zend_hash.c:673)
==3077==by 0x888B77: zend_deactivate_modules (zend.c:874)
==3077==by 0x813040: php_request_shutdown (main.c:1497)
==3077==by 0x92C04A: main (php_cli.c:1320)
==3077==
==3077== Invalid read of size 1
==3077==at 0x4C23DB9: strncmp (mc_replace_strmem.c:314)
==3077==by 0x85C3750: __add_to_environ (in /lib64/libc-2.5.so)
==3077==by 0x85C34CD: putenv (in /lib64/libc-2.5.so)
==3077==by 0x4C24173: putenv (mc_replace_strmem.c:743)
==3077==by 0x75088C: php_putenv_destructor (basic_functions.c: 
3822)

==3077==by 0x89901B: zend_hash_destroy (zend_hash.c:526)
==3077==by 0x7514CC: zm_deactivate_basic (basic_functions.c:4143)
==3077==by 0x892D02: module_registry_cleanup (zend_API.c:2119)
==3077==by 0x899602: zend_hash_apply (zend_hash.c:673)
==3077==by 0x888B77: zend_deactivate_modules (zend.c:874)
==3077==by 0x813040: php_request_shutdown (main.c:1497)
==3077==by 0x92C04A: main (php_cli.c:1320)
==3077==  Address 0x8ea3d08 is 0 bytes inside a block of size 18  
free'd

==3077==at 0x4C2292E: free (vg_replace_malloc.c:323)
==3077==by 0x864AD6: _efree (zend_alloc.c:2291)
==3077==by 0x7508AE: php_putenv_destructor (basic_functions.c: 
3823)

==3077==by 0x89901B: zend_hash_destroy (zend_hash.c:526)
==3077==by 0x7514CC: zm_deactivate_basic (basic_functions.c:4143)
==3077==by 0x892D02: module_registry_cleanup (zend_API.c:2119)
==3077==by 0x899602: zend_hash_apply (zend_hash.c:673)
==3077==by 0x888B77: zend_deactivate_modules (zend.c:874)
==3077==by 0x813040: php_request_shutdown (main.c:1497)
==3077==by 0x92C04A: main (php_cli.c:1320)
==3077==
==3077== Invalid read of size 1
==3077==at 0x4C23DC6: strncmp (mc_replace_strmem.c:314)
==3077==by 0x85C3750: __add_to_environ (in /lib64/li

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

2008-05-07 Thread Felipe Pena
Hi,
Maybe we could use setenv() instead?

"The setenv() function is preferred over this function."
http://www.opengroup.org/onlinepubs/009695399/functions/putenv.html

Em Qua, 2008-05-07 às 12:42 +0400, Antony Dovgal escreveu:
> On 06.05.2008 22:01, Ilia Alshanetsky wrote:
> > iliaa   Tue May  6 18:01:36 2008 UTC
> > 
> >   Modified files:  (Branch: PHP_5_3)
> > /php-src/ext/standard   basic_functions.c 
> >   Log:
> >   Fixed bug #44836 (putenv() crashes, avoid direct reference of environ in
> >   POSIX systems)
> >   
> >   # Original patch by delphij at FreeBSD dot org
> 
> The patch may be correct for FreeBSD, but this is what it causes on Linux:
> # cat sapi/cgi/tests/001.mem
> ==3077== Invalid read of size 1
> ==3077==at 0x4C23DB9: strncmp (mc_replace_strmem.c:314)
> ==3077==by 0x85C364D: unsetenv (in /lib64/libc-2.5.so)
> ==3077==by 0x4C24203: unsetenv (mc_replace_strmem.c:760)
> ==3077==by 0x7508BD: php_putenv_destructor (basic_functions.c:3826)
> ==3077==by 0x89901B: zend_hash_destroy (zend_hash.c:526)
> ==3077==by 0x7514CC: zm_deactivate_basic (basic_functions.c:4143)
> ==3077==by 0x892D02: module_registry_cleanup (zend_API.c:2119)
> ==3077==by 0x899602: zend_hash_apply (zend_hash.c:673)
> ==3077==by 0x888B77: zend_deactivate_modules (zend.c:874)
> ==3077==by 0x813040: php_request_shutdown (main.c:1497)
> ==3077==by 0x92C04A: main (php_cli.c:1320)
> ==3077==  Address 0x8ea3d08 is 0 bytes inside a block of size 18 free'd
> ==3077==at 0x4C2292E: free (vg_replace_malloc.c:323)
> ==3077==by 0x864AD6: _efree (zend_alloc.c:2291)
> ==3077==by 0x7508AE: php_putenv_destructor (basic_functions.c:3823)
> ==3077==by 0x89901B: zend_hash_destroy (zend_hash.c:526)
> ==3077==by 0x7514CC: zm_deactivate_basic (basic_functions.c:4143)
> ==3077==by 0x892D02: module_registry_cleanup (zend_API.c:2119)
> ==3077==by 0x899602: zend_hash_apply (zend_hash.c:673)
> ==3077==by 0x888B77: zend_deactivate_modules (zend.c:874)
> ==3077==by 0x813040: php_request_shutdown (main.c:1497)
> ==3077==by 0x92C04A: main (php_cli.c:1320)
> ==3077==
> ==3077== Invalid read of size 1
> ==3077==at 0x4C23DC6: strncmp (mc_replace_strmem.c:314)
> ==3077==by 0x85C364D: unsetenv (in /lib64/libc-2.5.so)
> ==3077==by 0x4C24203: unsetenv (mc_replace_strmem.c:760)
> ==3077==by 0x7508BD: php_putenv_destructor (basic_functions.c:3826)
> ==3077==by 0x89901B: zend_hash_destroy (zend_hash.c:526)
> ==3077==by 0x7514CC: zm_deactivate_basic (basic_functions.c:4143)
> ==3077==by 0x892D02: module_registry_cleanup (zend_API.c:2119)
> ==3077==by 0x899602: zend_hash_apply (zend_hash.c:673)
> ==3077==by 0x888B77: zend_deactivate_modules (zend.c:874)
> ==3077==by 0x813040: php_request_shutdown (main.c:1497)
> ==3077==by 0x92C04A: main (php_cli.c:1320)
> ==3077==  Address 0x8ea3d08 is 0 bytes inside a block of size 18 free'd
> ==3077==at 0x4C2292E: free (vg_replace_malloc.c:323)
> ==3077==by 0x864AD6: _efree (zend_alloc.c:2291)
> ==3077==by 0x7508AE: php_putenv_destructor (basic_functions.c:3823)
> ==3077==by 0x89901B: zend_hash_destroy (zend_hash.c:526)
> ==3077==by 0x7514CC: zm_deactivate_basic (basic_functions.c:4143)
> ==3077==by 0x892D02: module_registry_cleanup (zend_API.c:2119)
> ==3077==by 0x899602: zend_hash_apply (zend_hash.c:673)
> ==3077==by 0x888B77: zend_deactivate_modules (zend.c:874)
> ==3077==by 0x813040: php_request_shutdown (main.c:1497)
> ==3077==by 0x92C04A: main (php_cli.c:1320)
> ==3077==
> ==3077== Invalid read of size 1
> ==3077==at 0x4C23DB9: strncmp (mc_replace_strmem.c:314)
> ==3077==by 0x85C3750: __add_to_environ (in /lib64/libc-2.5.so)
> ==3077==by 0x85C34CD: putenv (in /lib64/libc-2.5.so)
> ==3077==by 0x4C24173: putenv (mc_replace_strmem.c:743)
> ==3077==by 0x75088C: php_putenv_destructor (basic_functions.c:3822)
> ==3077==by 0x89901B: zend_hash_destroy (zend_hash.c:526)
> ==3077==by 0x7514CC: zm_deactivate_basic (basic_functions.c:4143)
> ==3077==by 0x892D02: module_registry_cleanup (zend_API.c:2119)
> ==3077==by 0x899602: zend_hash_apply (zend_hash.c:673)
> ==3077==by 0x888B77: zend_deactivate_modules (zend.c:874)
> ==3077==by 0x813040: php_request_shutdown (main.c:1497)
> ==3077==by 0x92C04A: main (php_cli.c:1320)
> ==3077==  Address 0x8ea3d08 is 0 bytes inside a block of size 18 free'd
> ==3077==at 0x4C2292E: free (vg_replace_malloc.c:323)
> ==3077==by 0x864AD6: _efree (zend_alloc.c:2291)
> ==3077==by 0x7508AE: php_putenv_destructor (basic_functions.c:3823)
> ==3077==by 0x89901B: zend_hash_destroy (zend_hash.c:526)
> ==3077==by 0x7514CC: zm_deactivate_basic (basic_functions.c:4143)
> ==3077==by 0x892D02: module_registry_cleanup (zend_API.c:2119)
> ==3077==by 0x899602: zend_hash_apply (zend_hash.c:673)
> ==3077==by 0x888B77: zend_deactivate_modules (zend.c:874)

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

2008-05-07 Thread Antony Dovgal

On 06.05.2008 22:01, Ilia Alshanetsky wrote:

iliaa   Tue May  6 18:01:36 2008 UTC

  Modified files:  (Branch: PHP_5_3)
/php-src/ext/standard	basic_functions.c 
  Log:

  Fixed bug #44836 (putenv() crashes, avoid direct reference of environ in
  POSIX systems)
  
  # Original patch by delphij at FreeBSD dot org


The patch may be correct for FreeBSD, but this is what it causes on Linux:
# cat sapi/cgi/tests/001.mem
==3077== Invalid read of size 1
==3077==at 0x4C23DB9: strncmp (mc_replace_strmem.c:314)
==3077==by 0x85C364D: unsetenv (in /lib64/libc-2.5.so)
==3077==by 0x4C24203: unsetenv (mc_replace_strmem.c:760)
==3077==by 0x7508BD: php_putenv_destructor (basic_functions.c:3826)
==3077==by 0x89901B: zend_hash_destroy (zend_hash.c:526)
==3077==by 0x7514CC: zm_deactivate_basic (basic_functions.c:4143)
==3077==by 0x892D02: module_registry_cleanup (zend_API.c:2119)
==3077==by 0x899602: zend_hash_apply (zend_hash.c:673)
==3077==by 0x888B77: zend_deactivate_modules (zend.c:874)
==3077==by 0x813040: php_request_shutdown (main.c:1497)
==3077==by 0x92C04A: main (php_cli.c:1320)
==3077==  Address 0x8ea3d08 is 0 bytes inside a block of size 18 free'd
==3077==at 0x4C2292E: free (vg_replace_malloc.c:323)
==3077==by 0x864AD6: _efree (zend_alloc.c:2291)
==3077==by 0x7508AE: php_putenv_destructor (basic_functions.c:3823)
==3077==by 0x89901B: zend_hash_destroy (zend_hash.c:526)
==3077==by 0x7514CC: zm_deactivate_basic (basic_functions.c:4143)
==3077==by 0x892D02: module_registry_cleanup (zend_API.c:2119)
==3077==by 0x899602: zend_hash_apply (zend_hash.c:673)
==3077==by 0x888B77: zend_deactivate_modules (zend.c:874)
==3077==by 0x813040: php_request_shutdown (main.c:1497)
==3077==by 0x92C04A: main (php_cli.c:1320)
==3077==
==3077== Invalid read of size 1
==3077==at 0x4C23DC6: strncmp (mc_replace_strmem.c:314)
==3077==by 0x85C364D: unsetenv (in /lib64/libc-2.5.so)
==3077==by 0x4C24203: unsetenv (mc_replace_strmem.c:760)
==3077==by 0x7508BD: php_putenv_destructor (basic_functions.c:3826)
==3077==by 0x89901B: zend_hash_destroy (zend_hash.c:526)
==3077==by 0x7514CC: zm_deactivate_basic (basic_functions.c:4143)
==3077==by 0x892D02: module_registry_cleanup (zend_API.c:2119)
==3077==by 0x899602: zend_hash_apply (zend_hash.c:673)
==3077==by 0x888B77: zend_deactivate_modules (zend.c:874)
==3077==by 0x813040: php_request_shutdown (main.c:1497)
==3077==by 0x92C04A: main (php_cli.c:1320)
==3077==  Address 0x8ea3d08 is 0 bytes inside a block of size 18 free'd
==3077==at 0x4C2292E: free (vg_replace_malloc.c:323)
==3077==by 0x864AD6: _efree (zend_alloc.c:2291)
==3077==by 0x7508AE: php_putenv_destructor (basic_functions.c:3823)
==3077==by 0x89901B: zend_hash_destroy (zend_hash.c:526)
==3077==by 0x7514CC: zm_deactivate_basic (basic_functions.c:4143)
==3077==by 0x892D02: module_registry_cleanup (zend_API.c:2119)
==3077==by 0x899602: zend_hash_apply (zend_hash.c:673)
==3077==by 0x888B77: zend_deactivate_modules (zend.c:874)
==3077==by 0x813040: php_request_shutdown (main.c:1497)
==3077==by 0x92C04A: main (php_cli.c:1320)
==3077==
==3077== Invalid read of size 1
==3077==at 0x4C23DB9: strncmp (mc_replace_strmem.c:314)
==3077==by 0x85C3750: __add_to_environ (in /lib64/libc-2.5.so)
==3077==by 0x85C34CD: putenv (in /lib64/libc-2.5.so)
==3077==by 0x4C24173: putenv (mc_replace_strmem.c:743)
==3077==by 0x75088C: php_putenv_destructor (basic_functions.c:3822)
==3077==by 0x89901B: zend_hash_destroy (zend_hash.c:526)
==3077==by 0x7514CC: zm_deactivate_basic (basic_functions.c:4143)
==3077==by 0x892D02: module_registry_cleanup (zend_API.c:2119)
==3077==by 0x899602: zend_hash_apply (zend_hash.c:673)
==3077==by 0x888B77: zend_deactivate_modules (zend.c:874)
==3077==by 0x813040: php_request_shutdown (main.c:1497)
==3077==by 0x92C04A: main (php_cli.c:1320)
==3077==  Address 0x8ea3d08 is 0 bytes inside a block of size 18 free'd
==3077==at 0x4C2292E: free (vg_replace_malloc.c:323)
==3077==by 0x864AD6: _efree (zend_alloc.c:2291)
==3077==by 0x7508AE: php_putenv_destructor (basic_functions.c:3823)
==3077==by 0x89901B: zend_hash_destroy (zend_hash.c:526)
==3077==by 0x7514CC: zm_deactivate_basic (basic_functions.c:4143)
==3077==by 0x892D02: module_registry_cleanup (zend_API.c:2119)
==3077==by 0x899602: zend_hash_apply (zend_hash.c:673)
==3077==by 0x888B77: zend_deactivate_modules (zend.c:874)
==3077==by 0x813040: php_request_shutdown (main.c:1497)
==3077==by 0x92C04A: main (php_cli.c:1320)
==3077==
==3077== Invalid read of size 1
==3077==at 0x4C23DC6: strncmp (mc_replace_strmem.c:314)
==3077==by 0x85C3750: __add_to_environ (in /lib64/libc-2.5.so)
==3077==by 0x85C34CD: putenv (in /lib64/libc-2.5.so)
==3077==by 0x4C24173: putenv (mc_replace_strmem.c:743)
==3077==by 0x75088