Re: [PHP-CVS] cvs: php-src /ext/bcmath/libbcmath/src div.c init.c num2str.c

2007-07-12 Thread Nuno Lopes

if you are using safe_emalloc() you can remove all those ' == NULL' tests.
Nuno

On 7/10/07, Antony Dovgal [EMAIL PROTECTED] wrote:

tony2001Tue Jul 10 11:07:56 2007 UTC

 Modified files:
   /php-src/ext/bcmath/libbcmath/src   div.c init.c num2str.c
 Log:
 use safe_emalloc()


http://cvs.php.net/viewvc.cgi/php-src/ext/bcmath/libbcmath/src/div.c?r1=1.3r2=1.4diff_format=u
Index: php-src/ext/bcmath/libbcmath/src/div.c
diff -u php-src/ext/bcmath/libbcmath/src/div.c:1.3 
php-src/ext/bcmath/libbcmath/src/div.c:1.4
--- php-src/ext/bcmath/libbcmath/src/div.c:1.3  Fri Nov 22 09:25:29 2002
+++ php-src/ext/bcmath/libbcmath/src/div.c  Tue Jul 10 11:07:56 2007
@@ -127,13 +127,13 @@
extra = scale - scale1;
  else
extra = 0;
-  num1 = (unsigned char *) emalloc (n1-n_len+n1-n_scale+extra+2);
+  num1 = (unsigned char *) safe_emalloc (1, n1-n_len+n1-n_scale, extra+2);
  if (num1 == NULL) bc_out_of_memory();
  memset (num1, 0, n1-n_len+n1-n_scale+extra+2);
  memcpy (num1+1, n1-n_value, n1-n_len+n1-n_scale);

  len2 = n2-n_len + scale2;
-  num2 = (unsigned char *) emalloc (len2+1);
+  num2 = (unsigned char *) safe_emalloc (1, len2, 1);
  if (num2 == NULL) bc_out_of_memory();
  memcpy (num2, n2-n_value, len2);
  *(num2+len2) = 0;
@@ -164,7 +164,7 @@
  memset (qval-n_value, 0, qdigits);

  /* Allocate storage for the temporary storage mval. */
-  mval = (unsigned char *) emalloc (len2+1);
+  mval = (unsigned char *) safe_emalloc (1, len2, 1);
  if (mval == NULL) bc_out_of_memory ();

  /* Now for the full divide algorithm. */
http://cvs.php.net/viewvc.cgi/php-src/ext/bcmath/libbcmath/src/init.c?r1=1.6r2=1.7diff_format=u
Index: php-src/ext/bcmath/libbcmath/src/init.c
diff -u php-src/ext/bcmath/libbcmath/src/init.c:1.6 
php-src/ext/bcmath/libbcmath/src/init.c:1.7
--- php-src/ext/bcmath/libbcmath/src/init.c:1.6 Tue Dec  9 23:59:33 2003
+++ php-src/ext/bcmath/libbcmath/src/init.c Tue Jul 10 11:07:56 2007
@@ -51,7 +51,7 @@
  bc_num temp;

  /* PHP Change:  malloc() - pemalloc(), removed free_list code */
-  temp = (bc_num) pemalloc (sizeof(bc_struct)+length+scale, persistent);
+  temp = (bc_num) safe_pemalloc (1, sizeof(bc_struct)+length, scale, 
persistent);
 #if 0
  if (_bc_Free_list != NULL) {
temp = _bc_Free_list;
@@ -66,7 +66,7 @@
  temp-n_scale = scale;
  temp-n_refs = 1;
  /* PHP Change:  malloc() - pemalloc() */
-  temp-n_ptr = (char *) pemalloc (length+scale, persistent);
+  temp-n_ptr = (char *) safe_pemalloc (1, length, scale, persistent);
  if (temp-n_ptr == NULL) bc_out_of_memory();
  temp-n_value = temp-n_ptr;
  memset (temp-n_ptr, 0, length+scale);
http://cvs.php.net/viewvc.cgi/php-src/ext/bcmath/libbcmath/src/num2str.c?r1=1.2r2=1.3diff_format=u
Index: php-src/ext/bcmath/libbcmath/src/num2str.c
diff -u php-src/ext/bcmath/libbcmath/src/num2str.c:1.2 
php-src/ext/bcmath/libbcmath/src/num2str.c:1.3
--- php-src/ext/bcmath/libbcmath/src/num2str.c:1.2  Sun Nov 26 09:34:01 2000
+++ php-src/ext/bcmath/libbcmath/src/num2str.c  Tue Jul 10 11:07:56 2007
@@ -51,9 +51,9 @@
  /* Allocate the string memory. */
  signch = ( num-n_sign == PLUS ? 0 : 1 );  /* Number of sign chars. */
  if (num-n_scale  0)
-str = (char *) emalloc (num-n_len + num-n_scale + 2 + signch);
+str = (char *) safe_emalloc (1, num-n_len + num-n_scale, 2 + signch);
  else
-str = (char *) emalloc (num-n_len + 1 + signch);
+str = (char *) safe_emalloc (1, num-n_len, 1 + signch);
  if (str == NULL) bc_out_of_memory();

  /* The negative sign if needed. */

--
PHP CVS Mailing List (http://www.php.net/)
To unsubscribe, visit: http://www.php.net/unsub.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_mysql .cvsignore /ext/pdo_oci .cvsignore /ext/pdo_pgsql .cvsignore

2007-07-14 Thread Nuno Lopes
nlopess Sat Jul 14 17:22:27 2007 UTC

  Modified files:  
/php-src/ext/pdo_mysql  .cvsignore 
/php-src/ext/pdo_oci.cvsignore 
/php-src/ext/pdo_pgsql  .cvsignore 
  Log:
  ignore *.gcda
  
http://cvs.php.net/viewvc.cgi/php-src/ext/pdo_mysql/.cvsignore?r1=1.3r2=1.4diff_format=u
Index: php-src/ext/pdo_mysql/.cvsignore
diff -u php-src/ext/pdo_mysql/.cvsignore:1.3 
php-src/ext/pdo_mysql/.cvsignore:1.4
--- php-src/ext/pdo_mysql/.cvsignore:1.3Mon Jun  4 18:11:38 2007
+++ php-src/ext/pdo_mysql/.cvsignoreSat Jul 14 17:22:26 2007
@@ -1,5 +1,6 @@
 .deps
 *.gcno
+*.gcda
 *.lo
 *.la
 .*.swp
http://cvs.php.net/viewvc.cgi/php-src/ext/pdo_oci/.cvsignore?r1=1.4r2=1.5diff_format=u
Index: php-src/ext/pdo_oci/.cvsignore
diff -u php-src/ext/pdo_oci/.cvsignore:1.4 php-src/ext/pdo_oci/.cvsignore:1.5
--- php-src/ext/pdo_oci/.cvsignore:1.4  Mon Jun  4 18:11:38 2007
+++ php-src/ext/pdo_oci/.cvsignore  Sat Jul 14 17:22:26 2007
@@ -1,5 +1,6 @@
 .deps
 *.gcno
+*.gcda
 *.lo
 *.la
 .*.swp
http://cvs.php.net/viewvc.cgi/php-src/ext/pdo_pgsql/.cvsignore?r1=1.3r2=1.4diff_format=u
Index: php-src/ext/pdo_pgsql/.cvsignore
diff -u php-src/ext/pdo_pgsql/.cvsignore:1.3 
php-src/ext/pdo_pgsql/.cvsignore:1.4
--- php-src/ext/pdo_pgsql/.cvsignore:1.3Mon Jun  4 18:11:38 2007
+++ php-src/ext/pdo_pgsql/.cvsignoreSat Jul 14 17:22:26 2007
@@ -1,4 +1,5 @@
 *.gcno
+*.gcda
 .deps
 *.lo
 *.la

-- 
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/pdo_mysql .cvsignore /ext/pdo_oci .cvsignore /ext/pdo_pgsql .cvsignore

2007-07-14 Thread Nuno Lopes
nlopess Sat Jul 14 17:29:45 2007 UTC

  Modified files:  (Branch: PHP_5_2)
/php-src/ext/pdo_mysql  .cvsignore 
/php-src/ext/pdo_oci.cvsignore 
/php-src/ext/pdo_pgsql  .cvsignore 
  Log:
  ignore *.gcda
  
http://cvs.php.net/viewvc.cgi/php-src/ext/pdo_mysql/.cvsignore?r1=1.2.4.1r2=1.2.4.2diff_format=u
Index: php-src/ext/pdo_mysql/.cvsignore
diff -u php-src/ext/pdo_mysql/.cvsignore:1.2.4.1 
php-src/ext/pdo_mysql/.cvsignore:1.2.4.2
--- php-src/ext/pdo_mysql/.cvsignore:1.2.4.1Mon Jun  4 18:13:53 2007
+++ php-src/ext/pdo_mysql/.cvsignoreSat Jul 14 17:29:44 2007
@@ -1,5 +1,6 @@
 .deps
 *.gcno
+*.gcda
 *.lo
 *.la
 .*.swp
http://cvs.php.net/viewvc.cgi/php-src/ext/pdo_oci/.cvsignore?r1=1.3.4.1r2=1.3.4.2diff_format=u
Index: php-src/ext/pdo_oci/.cvsignore
diff -u php-src/ext/pdo_oci/.cvsignore:1.3.4.1 
php-src/ext/pdo_oci/.cvsignore:1.3.4.2
--- php-src/ext/pdo_oci/.cvsignore:1.3.4.1  Mon Jun  4 18:13:53 2007
+++ php-src/ext/pdo_oci/.cvsignore  Sat Jul 14 17:29:45 2007
@@ -1,5 +1,6 @@
 .deps
 *.gcno
+*.gcda
 *.lo
 *.la
 .*.swp
http://cvs.php.net/viewvc.cgi/php-src/ext/pdo_pgsql/.cvsignore?r1=1.2.4.1r2=1.2.4.2diff_format=u
Index: php-src/ext/pdo_pgsql/.cvsignore
diff -u php-src/ext/pdo_pgsql/.cvsignore:1.2.4.1 
php-src/ext/pdo_pgsql/.cvsignore:1.2.4.2
--- php-src/ext/pdo_pgsql/.cvsignore:1.2.4.1Mon Jun  4 18:13:53 2007
+++ php-src/ext/pdo_pgsql/.cvsignoreSat Jul 14 17:29:45 2007
@@ -1,5 +1,6 @@
 .deps
 *.gcno
+*.gcda
 *.lo
 *.la
 .*.swp

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



[PHP-CVS] cvs: php-src /ext/filter .cvsignore /ext/pdo .cvsignore /ext/pdo_sqlite .cvsignore /ext/unicode .cvsignore /ext/xmlreader .cvsignore /ext/xmlwriter .cvsignore /ext/zip .cvsignore /ext

2007-07-14 Thread Nuno Lopes
nlopess Sat Jul 14 17:35:23 2007 UTC

  Modified files:  
/php-src/ext/filter .cvsignore 
/php-src/ext/pdo.cvsignore 
/php-src/ext/pdo_sqlite .cvsignore 
/php-src/ext/unicode.cvsignore 
/php-src/ext/xmlreader  .cvsignore 
/php-src/ext/xmlwriter  .cvsignore 
/php-src/ext/zip.cvsignore 
/php-src/ext/zip/lib.cvsignore 
  Log:
  ignore *.gcda
  
http://cvs.php.net/viewvc.cgi/php-src/ext/filter/.cvsignore?r1=1.2r2=1.3diff_format=u
Index: php-src/ext/filter/.cvsignore
diff -u php-src/ext/filter/.cvsignore:1.2 php-src/ext/filter/.cvsignore:1.3
--- php-src/ext/filter/.cvsignore:1.2   Mon Jun  4 18:11:38 2007
+++ php-src/ext/filter/.cvsignore   Sat Jul 14 17:35:23 2007
@@ -1,4 +1,5 @@
 *.gcno
+*.gcda
 .deps
 Makefile
 *.lo
http://cvs.php.net/viewvc.cgi/php-src/ext/pdo/.cvsignore?r1=1.6r2=1.7diff_format=u
Index: php-src/ext/pdo/.cvsignore
diff -u php-src/ext/pdo/.cvsignore:1.6 php-src/ext/pdo/.cvsignore:1.7
--- php-src/ext/pdo/.cvsignore:1.6  Mon Jun  4 18:11:38 2007
+++ php-src/ext/pdo/.cvsignore  Sat Jul 14 17:35:23 2007
@@ -1,5 +1,6 @@
 .deps
 *.gcno
+*.gcda
 *.lo
 *.la
 .*.swp
http://cvs.php.net/viewvc.cgi/php-src/ext/pdo_sqlite/.cvsignore?r1=1.6r2=1.7diff_format=u
Index: php-src/ext/pdo_sqlite/.cvsignore
diff -u php-src/ext/pdo_sqlite/.cvsignore:1.6 
php-src/ext/pdo_sqlite/.cvsignore:1.7
--- php-src/ext/pdo_sqlite/.cvsignore:1.6   Mon Jun  4 18:11:38 2007
+++ php-src/ext/pdo_sqlite/.cvsignore   Sat Jul 14 17:35:23 2007
@@ -1,4 +1,5 @@
 *.gcno
+*.gcda
 .deps
 *.lo
 *.la
http://cvs.php.net/viewvc.cgi/php-src/ext/unicode/.cvsignore?r1=1.2r2=1.3diff_format=u
Index: php-src/ext/unicode/.cvsignore
diff -u php-src/ext/unicode/.cvsignore:1.2 php-src/ext/unicode/.cvsignore:1.3
--- php-src/ext/unicode/.cvsignore:1.2  Mon Jun  4 18:11:38 2007
+++ php-src/ext/unicode/.cvsignore  Sat Jul 14 17:35:23 2007
@@ -1,4 +1,5 @@
 *.gcno
+*.gcda
 *.lo
 *.la
 .deps
http://cvs.php.net/viewvc.cgi/php-src/ext/xmlreader/.cvsignore?r1=1.2r2=1.3diff_format=u
Index: php-src/ext/xmlreader/.cvsignore
diff -u php-src/ext/xmlreader/.cvsignore:1.2 
php-src/ext/xmlreader/.cvsignore:1.3
--- php-src/ext/xmlreader/.cvsignore:1.2Mon Jun  4 18:11:38 2007
+++ php-src/ext/xmlreader/.cvsignoreSat Jul 14 17:35:23 2007
@@ -1,5 +1,6 @@
 #*#
 *.gcno
+*.gcda
 *.dsw
 *.la
 *.lo
http://cvs.php.net/viewvc.cgi/php-src/ext/xmlwriter/.cvsignore?r1=1.2r2=1.3diff_format=u
Index: php-src/ext/xmlwriter/.cvsignore
diff -u php-src/ext/xmlwriter/.cvsignore:1.2 
php-src/ext/xmlwriter/.cvsignore:1.3
--- php-src/ext/xmlwriter/.cvsignore:1.2Mon Jun  4 18:11:38 2007
+++ php-src/ext/xmlwriter/.cvsignoreSat Jul 14 17:35:23 2007
@@ -1,5 +1,6 @@
 #*#
 *.gcno
+*.gcda
 *.dsw
 *.la
 *.lo
http://cvs.php.net/viewvc.cgi/php-src/ext/zip/.cvsignore?r1=1.9r2=1.10diff_format=u
Index: php-src/ext/zip/.cvsignore
diff -u php-src/ext/zip/.cvsignore:1.9 php-src/ext/zip/.cvsignore:1.10
--- php-src/ext/zip/.cvsignore:1.9  Mon Jun  4 18:11:38 2007
+++ php-src/ext/zip/.cvsignore  Sat Jul 14 17:35:23 2007
@@ -1,3 +1,4 @@
 *.lo
 .libs
 *.gcno
+*.gcda
http://cvs.php.net/viewvc.cgi/php-src/ext/zip/lib/.cvsignore?r1=1.2r2=1.3diff_format=u
Index: php-src/ext/zip/lib/.cvsignore
diff -u php-src/ext/zip/lib/.cvsignore:1.2 php-src/ext/zip/lib/.cvsignore:1.3
--- php-src/ext/zip/lib/.cvsignore:1.2  Mon Jun  4 18:11:38 2007
+++ php-src/ext/zip/lib/.cvsignore  Sat Jul 14 17:35:23 2007
@@ -1,2 +1,3 @@
 *.lo
 *.gcno
+*.gcda

-- 
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/tidy php_tidy.def

2007-07-17 Thread Nuno Lopes
nlopess Tue Jul 17 10:29:32 2007 UTC

  Modified files:  (Branch: PHP_5_2)
/php-src/ext/tidy   php_tidy.def 
  Log:
  update for latest library rlease
  
http://cvs.php.net/viewvc.cgi/php-src/ext/tidy/php_tidy.def?r1=1.2.2.1r2=1.2.2.1.2.1diff_format=u
Index: php-src/ext/tidy/php_tidy.def
diff -u php-src/ext/tidy/php_tidy.def:1.2.2.1 
php-src/ext/tidy/php_tidy.def:1.2.2.1.2.1
--- php-src/ext/tidy/php_tidy.def:1.2.2.1   Wed Apr 19 20:57:30 2006
+++ php-src/ext/tidy/php_tidy.def   Tue Jul 17 10:29:32 2007
@@ -12,8 +12,6 @@
 tidyBufGetByte
 tidyBufEndOfInput
 tidyBufUngetByte
-initInputBuffer
-initOutputBuffer
 tidyCreate
 tidyRelease
 tidySetAppData

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



[PHP-CVS] cvs: php-src /ext/tidy php_tidy.def

2007-07-17 Thread Nuno Lopes
nlopess Tue Jul 17 10:30:51 2007 UTC

  Modified files:  
/php-src/ext/tidy   php_tidy.def 
  Log:
  MFB: update
  
http://cvs.php.net/viewvc.cgi/php-src/ext/tidy/php_tidy.def?r1=1.3r2=1.4diff_format=u
Index: php-src/ext/tidy/php_tidy.def
diff -u php-src/ext/tidy/php_tidy.def:1.3 php-src/ext/tidy/php_tidy.def:1.4
--- php-src/ext/tidy/php_tidy.def:1.3   Wed Apr 19 20:37:55 2006
+++ php-src/ext/tidy/php_tidy.def   Tue Jul 17 10:30:50 2007
@@ -12,8 +12,6 @@
 tidyBufGetByte
 tidyBufEndOfInput
 tidyBufUngetByte
-initInputBuffer
-initOutputBuffer
 tidyCreate
 tidyRelease
 tidySetAppData

-- 
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/tests config.inc

2007-07-18 Thread Nuno Lopes
nlopess Wed Jul 18 12:28:08 2007 UTC

  Modified files:  
/php-src/ext/pdo_pgsql/testsconfig.inc 
  Log:
  attempt to fix pdo_pgsql tests in HEAD
  
http://cvs.php.net/viewvc.cgi/php-src/ext/pdo_pgsql/tests/config.inc?r1=1.1r2=1.2diff_format=u
Index: php-src/ext/pdo_pgsql/tests/config.inc
diff -u /dev/null php-src/ext/pdo_pgsql/tests/config.inc:1.2
--- /dev/null   Wed Jul 18 12:28:08 2007
+++ php-src/ext/pdo_pgsql/tests/config.inc  Wed Jul 18 12:28:08 2007
@@ -0,0 +1,14 @@
+?php # vim:se ft=php:
+if (false !== getenv('PDO_PGSQL_TEST_DSN')) {
+   # user set them from their shell
+   $config['ENV']['PDOTEST_DSN'] = getenv('PDO_PGSQL_TEST_DSN');
+   if (false !== getenv('PDO_PGSQL_TEST_ATTR')) {
+   $config['ENV']['PDOTEST_ATTR'] = getenv('PDO_PGSQL_TEST_ATTR');
+   }
+} else {
+   $config['ENV']['PDOTEST_DSN'] = 'pgsql:host=localhost port=5432 
dbname=test user=root password=';
+}
+
+foreach ($config['ENV'] as $k = $v) {
+   putenv($k=$v);
+}

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

2007-07-18 Thread Nuno Lopes
nlopess Wed Jul 18 18:06:55 2007 UTC

  Modified files:  (Branch: PHP_5_2)
/php-srcNEWS 
  Log:
  fix oci8 entries for Chris Jones
  
http://cvs.php.net/viewvc.cgi/php-src/NEWS?r1=1.2027.2.547.2.838r2=1.2027.2.547.2.839diff_format=u
Index: php-src/NEWS
diff -u php-src/NEWS:1.2027.2.547.2.838 php-src/NEWS:1.2027.2.547.2.839
--- php-src/NEWS:1.2027.2.547.2.838 Tue Jul 17 13:28:43 2007
+++ php-src/NEWSWed Jul 18 18:06:55 2007
@@ -9,8 +9,6 @@
 - Improved openssl_x509_parse() to return extensions in readable form. (Dmitry)
 - Improved fix for MOPB-03-2007. (Ilia)
 - Corrected fix for CVE-2007-2872. (Ilia)
-- Enabled statement cache for non-persistent OCI8 connections.
-  (Chris Jones, Tony)
 - Enabled changing the size of statement cache for non-persistent OCI8
   connections. (Chris Jones, Tony)
 

-- 
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/ldap config.m4

2007-08-08 Thread Nuno Lopes
nlopess Wed Aug  8 11:37:44 2007 UTC

  Modified files:  (Branch: PHP_5_2)
/php-srcNEWS 
/php-src/ext/ldap   config.m4 
  Log:
  +- Fixed bug #41973 (./configure --with-ldap=shared fails with
  
http://cvs.php.net/viewvc.cgi/php-src/NEWS?r1=1.2027.2.547.2.884r2=1.2027.2.547.2.885diff_format=u
Index: php-src/NEWS
diff -u php-src/NEWS:1.2027.2.547.2.884 php-src/NEWS:1.2027.2.547.2.885
--- php-src/NEWS:1.2027.2.547.2.884 Wed Aug  8 07:41:09 2007
+++ php-src/NEWSWed Aug  8 11:37:44 2007
@@ -9,6 +9,8 @@
   more than once). (crrodriguez at suse dot de, Ilia)
 - Fixed bug #42195 (C++ compiler required always). (Jani)
 - Fixed bug #42082 (NodeList length zero should be empty). (Hannes)
+- Fixed bug #41973 (./configure --with-ldap=shared fails with
+  LDFLAGS=-Wl,--as-needed). (Nuno)
 - Fixed bug #36492 (Userfilters can leak buckets). (Sara)
 
 02 Aug 2007, PHP 5.2.4RC1
http://cvs.php.net/viewvc.cgi/php-src/ext/ldap/config.m4?r1=1.39.2.6.2.1r2=1.39.2.6.2.2diff_format=u
Index: php-src/ext/ldap/config.m4
diff -u php-src/ext/ldap/config.m4:1.39.2.6.2.1 
php-src/ext/ldap/config.m4:1.39.2.6.2.2
--- php-src/ext/ldap/config.m4:1.39.2.6.2.1 Wed Oct 18 20:58:23 2006
+++ php-src/ext/ldap/config.m4  Wed Aug  8 11:37:44 2007
@@ -1,5 +1,5 @@
 dnl
-dnl $Id: config.m4,v 1.39.2.6.2.1 2006/10/18 20:58:23 tony2001 Exp $
+dnl $Id: config.m4,v 1.39.2.6.2.2 2007/08/08 11:37:44 nlopess Exp $
 dnl
 
 AC_DEFUN([PHP_LDAP_CHECKS], [
@@ -159,9 +159,9 @@
   
   dnl Save original values
   _SAVE_CPPFLAGS=$CPPFLAGS
-  _SAVE_LDFLAGS=$LDFLAGS
+  _SAVE_LIBS=$LIBS
   CPPFLAGS=$CPPFLAGS -I$LDAP_INCDIR
-  LDFLAGS=$LDFLAGS $LDAP_SHARED_LIBADD
+  LIBS=$LIBS $LDAP_SHARED_LIBADD
 
   dnl Check for 3 arg ldap_set_rebind_proc
   AC_CACHE_CHECK([for 3 arg ldap_set_rebind_proc], ac_cv_3arg_setrebindproc,
@@ -191,5 +191,5 @@
   
   dnl Restore original values
   CPPFLAGS=$_SAVE_CPPFLAGS
-  LDFLAGS=$_SAVE_LDFLAGS
+  LIBS=$_SAVE_LIBS
 fi 

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



[PHP-CVS] cvs: php-src /ext/ldap config.m4

2007-08-08 Thread Nuno Lopes
nlopess Wed Aug  8 11:38:32 2007 UTC

  Modified files:  
/php-src/ext/ldap   config.m4 
  Log:
  MFB: fix bug #41973
  
http://cvs.php.net/viewvc.cgi/php-src/ext/ldap/config.m4?r1=1.44r2=1.45diff_format=u
Index: php-src/ext/ldap/config.m4
diff -u php-src/ext/ldap/config.m4:1.44 php-src/ext/ldap/config.m4:1.45
--- php-src/ext/ldap/config.m4:1.44 Wed Oct 18 20:57:06 2006
+++ php-src/ext/ldap/config.m4  Wed Aug  8 11:38:32 2007
@@ -1,5 +1,5 @@
 dnl
-dnl $Id: config.m4,v 1.44 2006/10/18 20:57:06 tony2001 Exp $
+dnl $Id: config.m4,v 1.45 2007/08/08 11:38:32 nlopess Exp $
 dnl
 
 AC_DEFUN([PHP_LDAP_CHECKS], [
@@ -159,9 +159,9 @@
   
   dnl Save original values
   _SAVE_CPPFLAGS=$CPPFLAGS
-  _SAVE_LDFLAGS=$LDFLAGS
+  _SAVE_LIBS=$LIBS
   CPPFLAGS=$CPPFLAGS -I$LDAP_INCDIR
-  LDFLAGS=$LDFLAGS $LDAP_SHARED_LIBADD
+  LIBS=$LIBS $LDAP_SHARED_LIBADD
 
   dnl Check for 3 arg ldap_set_rebind_proc
   AC_CACHE_CHECK([for 3 arg ldap_set_rebind_proc], ac_cv_3arg_setrebindproc,
@@ -191,5 +191,5 @@
   
   dnl Restore original values
   CPPFLAGS=$_SAVE_CPPFLAGS
-  LDFLAGS=$_SAVE_LDFLAGS
+  LIBS=$_SAVE_LIBS
 fi 

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



[PHP-CVS] cvs: php-src /ext/mysqli/tests mysqli_real_connect.phpt

2007-08-11 Thread Nuno Lopes
nlopess Sat Aug 11 15:38:34 2007 UTC

  Modified files:  
/php-src/ext/mysqli/tests   mysqli_real_connect.phpt 
  Log:
  fix typo in tmp file path
  
http://cvs.php.net/viewvc.cgi/php-src/ext/mysqli/tests/mysqli_real_connect.phpt?r1=1.2r2=1.3diff_format=u
Index: php-src/ext/mysqli/tests/mysqli_real_connect.phpt
diff -u php-src/ext/mysqli/tests/mysqli_real_connect.phpt:1.2 
php-src/ext/mysqli/tests/mysqli_real_connect.phpt:1.3
--- php-src/ext/mysqli/tests/mysqli_real_connect.phpt:1.2   Thu Aug  9 
10:01:20 2007
+++ php-src/ext/mysqli/tests/mysqli_real_connect.phpt   Sat Aug 11 15:38:34 2007
@@ -117,7 +117,7 @@
if (!mysqli_real_connect($link, $host, $user, $passwd, $db, 
$port, $socket, 128))
printf([019] [%d] %s\n, mysqli_errno($link), 
mysqli_error($link));
 
-   $filename = sys_get_temp_dir() . DIRECTORY_SEPERATOR . 
'mysqli_real_connect_phpt';
+   $filename = sys_get_temp_dir() . DIRECTORY_SEPARATOR . 
'mysqli_real_connect_phpt';
if (!$fp = fopen($filename, 'w'))
printf([020] Cannot open temporary file %s\n, 
$filename);
 

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



[PHP-CVS] cvs: php-src /ext/tidy TODO

2007-09-01 Thread Nuno Lopes
nlopess Sat Sep  1 14:44:16 2007 UTC

  Removed files:   
/php-src/ext/tidy   TODO 
  Log:
  also remove this file in HEAD
  

-- 
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/pcre/tests bug42298.phpt

2007-09-01 Thread Nuno Lopes
nlopess Sat Sep  1 17:47:13 2007 UTC

  Added files: (Branch: PHP_5_2)
/php-src/ext/pcre/tests bug42298.phpt 
  Log:
  new test
  

http://cvs.php.net/viewvc.cgi/php-src/ext/pcre/tests/bug42298.phpt?view=markuprev=1.1
Index: php-src/ext/pcre/tests/bug42298.phpt
+++ php-src/ext/pcre/tests/bug42298.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/pcre config.w32 config0.m4 php_pcre.c

2007-09-01 Thread Nuno Lopes
nlopess Sat Sep  1 17:51:35 2007 UTC

  Modified files:  (Branch: PHP_5_2)
/php-src/ext/pcre   config.w32 config0.m4 php_pcre.c 
  Log:
  adapt for PCRE 7.3
  remove ability to include config.h from php_pcre.c, as it seems pretty 
useless and produces a few warnings
  
http://cvs.php.net/viewvc.cgi/php-src/ext/pcre/config.w32?r1=1.4.2.5.2.5r2=1.4.2.5.2.6diff_format=u
Index: php-src/ext/pcre/config.w32
diff -u php-src/ext/pcre/config.w32:1.4.2.5.2.5 
php-src/ext/pcre/config.w32:1.4.2.5.2.6
--- php-src/ext/pcre/config.w32:1.4.2.5.2.5 Fri Jun 15 19:09:24 2007
+++ php-src/ext/pcre/config.w32 Sat Sep  1 17:51:35 2007
@@ -1,11 +1,11 @@
-// $Id: config.w32,v 1.4.2.5.2.5 2007/06/15 19:09:24 nlopess Exp $
+// $Id: config.w32,v 1.4.2.5.2.6 2007/09/01 17:51:35 nlopess Exp $
 // vim:ft=javascript
 
 ARG_WITH(pcre-regex, Perl Compatible Regular Expressions, yes);
 
 if (PHP_PCRE_REGEX == yes) {
EXTENSION(pcre, php_pcre.c, PHP_PCRE_REGEX_SHARED,
-   -DNO_RECURSE -Iext/pcre/pcrelib);
+   -DNO_RECURSE -DHAVE_CONFIG_H -Iext/pcre/pcrelib);
ADD_SOURCES(ext/pcre/pcrelib, pcre_chartables.c 
pcre_ucp_searchfuncs.c pcre_compile.c pcre_config.c pcre_exec.c pcre_fullinfo.c 
pcre_get.c pcre_globals.c pcre_info.c pcre_maketables.c pcre_newline.c 
pcre_ord2utf8.c pcre_refcount.c pcre_study.c pcre_tables.c pcre_try_flipped.c 
pcre_valid_utf8.c pcre_version.c pcre_xclass.c, pcre);
ADD_DEF_FILE(ext\\pcre\\php_pcre.def);
 
http://cvs.php.net/viewvc.cgi/php-src/ext/pcre/config0.m4?r1=1.38.2.3.2.8r2=1.38.2.3.2.9diff_format=u
Index: php-src/ext/pcre/config0.m4
diff -u php-src/ext/pcre/config0.m4:1.38.2.3.2.8 
php-src/ext/pcre/config0.m4:1.38.2.3.2.9
--- php-src/ext/pcre/config0.m4:1.38.2.3.2.8Tue Jul  3 17:25:34 2007
+++ php-src/ext/pcre/config0.m4 Sat Sep  1 17:51:35 2007
@@ -1,5 +1,5 @@
 dnl
-dnl $Id: config0.m4,v 1.38.2.3.2.8 2007/07/03 17:25:34 sniper Exp $
+dnl $Id: config0.m4,v 1.38.2.3.2.9 2007/09/01 17:51:35 nlopess Exp $
 dnl
 
 dnl By default we'll compile and link against the bundled PCRE library
@@ -11,7 +11,7 @@
 
 if test $PHP_PCRE_REGEX != no; then
   if test $PHP_PCRE_REGEX = yes; then
-PHP_NEW_EXTENSION(pcre, pcrelib/pcre_chartables.c 
pcrelib/pcre_ucp_searchfuncs.c pcrelib/pcre_compile.c pcrelib/pcre_config.c 
pcrelib/pcre_exec.c pcrelib/pcre_fullinfo.c pcrelib/pcre_get.c 
pcrelib/pcre_globals.c pcrelib/pcre_info.c pcrelib/pcre_maketables.c 
pcrelib/pcre_newline.c pcrelib/pcre_ord2utf8.c pcrelib/pcre_refcount.c 
pcrelib/pcre_study.c pcrelib/pcre_tables.c pcrelib/pcre_try_flipped.c 
pcrelib/pcre_valid_utf8.c pcrelib/pcre_version.c pcrelib/pcre_xclass.c 
php_pcre.c, $ext_shared,,[EMAIL PROTECTED]@/pcrelib)
+PHP_NEW_EXTENSION(pcre, pcrelib/pcre_chartables.c 
pcrelib/pcre_ucp_searchfuncs.c pcrelib/pcre_compile.c pcrelib/pcre_config.c 
pcrelib/pcre_exec.c pcrelib/pcre_fullinfo.c pcrelib/pcre_get.c 
pcrelib/pcre_globals.c pcrelib/pcre_info.c pcrelib/pcre_maketables.c 
pcrelib/pcre_newline.c pcrelib/pcre_ord2utf8.c pcrelib/pcre_refcount.c 
pcrelib/pcre_study.c pcrelib/pcre_tables.c pcrelib/pcre_try_flipped.c 
pcrelib/pcre_valid_utf8.c pcrelib/pcre_version.c pcrelib/pcre_xclass.c 
php_pcre.c, $ext_shared,,-DHAVE_CONFIG_H [EMAIL PROTECTED]@/pcrelib)
 PHP_ADD_BUILD_DIR($ext_builddir/pcrelib)
 PHP_INSTALL_HEADERS([ext/pcre], [php_pcre.h pcrelib/])
 AC_DEFINE(HAVE_BUNDLED_PCRE, 1, [ ])
http://cvs.php.net/viewvc.cgi/php-src/ext/pcre/php_pcre.c?r1=1.168.2.9.2.19r2=1.168.2.9.2.20diff_format=u
Index: php-src/ext/pcre/php_pcre.c
diff -u php-src/ext/pcre/php_pcre.c:1.168.2.9.2.19 
php-src/ext/pcre/php_pcre.c:1.168.2.9.2.20
--- php-src/ext/pcre/php_pcre.c:1.168.2.9.2.19  Tue Jul 24 22:35:18 2007
+++ php-src/ext/pcre/php_pcre.c Sat Sep  1 17:51:35 2007
@@ -16,11 +16,7 @@
+--+
  */
 
-/* $Id: php_pcre.c,v 1.168.2.9.2.19 2007/07/24 22:35:18 tony2001 Exp $ */
-
-#ifdef HAVE_CONFIG_H
-#include config.h
-#endif
+/* $Id: php_pcre.c,v 1.168.2.9.2.20 2007/09/01 17:51:35 nlopess Exp $ */
 
 #include php.h
 #include php_ini.h

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



[PHP-CVS] cvs: php-src /ext/gd/libgd gd.c

2007-09-03 Thread Nuno Lopes
nlopess Mon Sep  3 14:34:42 2007 UTC

  Modified files:  
/php-src/ext/gd/libgd   gd.c 
  Log:
  MFB: malloc+memset == calloc
  # this was sitting here for quite a looong time..
  
http://cvs.php.net/viewvc.cgi/php-src/ext/gd/libgd/gd.c?r1=1.111r2=1.112diff_format=u
Index: php-src/ext/gd/libgd/gd.c
diff -u php-src/ext/gd/libgd/gd.c:1.111 php-src/ext/gd/libgd/gd.c:1.112
--- php-src/ext/gd/libgd/gd.c:1.111 Sun Aug 26 20:33:21 2007
+++ php-src/ext/gd/libgd/gd.c   Mon Sep  3 14:34:42 2007
@@ -129,8 +129,8 @@
return NULL;
}
 
-   im = (gdImage *) gdMalloc(sizeof(gdImage));
-   memset(im, 0, sizeof(gdImage));
+   im = (gdImage *) gdCalloc(1, sizeof(gdImage));
+
/* Row-major ever since gd 1.3 */
im-pixels = (unsigned char **) gdMalloc(sizeof(unsigned char *) * sy);
im-AA_opacity = (unsigned char **) gdMalloc(sizeof(unsigned char *) * 
sy);

-- 
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/pcre config.w32 config0.m4 upgrade-pcre.php /ext/pcre/pcrelib dftables.c pcre_chartables.c pcre_compile.c pcre_config.c pcre_exec.c pcre_fullinfo.c pcre_get.c pcr

2007-09-11 Thread Nuno Lopes
nlopess Tue Sep 11 16:17:34 2007 UTC

  Modified files:  (Branch: PHP_5_2)
/php-src/ext/pcre   config.w32 config0.m4 upgrade-pcre.php 
/php-src/ext/pcre/pcrelib   dftables.c pcre_chartables.c 
pcre_compile.c pcre_config.c pcre_exec.c 
pcre_fullinfo.c pcre_get.c pcre_globals.c 
pcre_info.c pcre_maketables.c 
pcre_newline.c pcre_ord2utf8.c 
pcre_refcount.c pcre_study.c 
pcre_tables.c pcre_try_flipped.c 
pcre_ucp_searchfuncs.c pcre_valid_utf8.c 
pcre_version.c pcre_xclass.c pcregrep.c 
pcreposix.c 
  Log:
  remove the -DHAVE_CONFIG_H switch again to fix things on windows
  this means that the upgrade script strips the #ifdef automatically
  http://cvs.php.net/viewvc.cgi/php-src/ext/pcre/config.w32?r1=1.4.2.5.2.6r2=1.4.2.5.2.7diff_format=u
Index: php-src/ext/pcre/config.w32
diff -u php-src/ext/pcre/config.w32:1.4.2.5.2.6 
php-src/ext/pcre/config.w32:1.4.2.5.2.7
--- php-src/ext/pcre/config.w32:1.4.2.5.2.6 Sat Sep  1 17:51:35 2007
+++ php-src/ext/pcre/config.w32 Tue Sep 11 16:17:33 2007
@@ -1,11 +1,11 @@
-// $Id: config.w32,v 1.4.2.5.2.6 2007/09/01 17:51:35 nlopess Exp $
+// $Id: config.w32,v 1.4.2.5.2.7 2007/09/11 16:17:33 nlopess Exp $
 // vim:ft=javascript
 
 ARG_WITH(pcre-regex, Perl Compatible Regular Expressions, yes);
 
 if (PHP_PCRE_REGEX == yes) {
EXTENSION(pcre, php_pcre.c, PHP_PCRE_REGEX_SHARED,
-   -DNO_RECURSE -DHAVE_CONFIG_H -Iext/pcre/pcrelib);
+   -DNO_RECURSE -Iext/pcre/pcrelib);
ADD_SOURCES(ext/pcre/pcrelib, pcre_chartables.c 
pcre_ucp_searchfuncs.c pcre_compile.c pcre_config.c pcre_exec.c pcre_fullinfo.c 
pcre_get.c pcre_globals.c pcre_info.c pcre_maketables.c pcre_newline.c 
pcre_ord2utf8.c pcre_refcount.c pcre_study.c pcre_tables.c pcre_try_flipped.c 
pcre_valid_utf8.c pcre_version.c pcre_xclass.c, pcre);
ADD_DEF_FILE(ext\\pcre\\php_pcre.def);
 
http://cvs.php.net/viewvc.cgi/php-src/ext/pcre/config0.m4?r1=1.38.2.3.2.9r2=1.38.2.3.2.10diff_format=u
Index: php-src/ext/pcre/config0.m4
diff -u php-src/ext/pcre/config0.m4:1.38.2.3.2.9 
php-src/ext/pcre/config0.m4:1.38.2.3.2.10
--- php-src/ext/pcre/config0.m4:1.38.2.3.2.9Sat Sep  1 17:51:35 2007
+++ php-src/ext/pcre/config0.m4 Tue Sep 11 16:17:33 2007
@@ -1,5 +1,5 @@
 dnl
-dnl $Id: config0.m4,v 1.38.2.3.2.9 2007/09/01 17:51:35 nlopess Exp $
+dnl $Id: config0.m4,v 1.38.2.3.2.10 2007/09/11 16:17:33 nlopess Exp $
 dnl
 
 dnl By default we'll compile and link against the bundled PCRE library
@@ -11,7 +11,7 @@
 
 if test $PHP_PCRE_REGEX != no; then
   if test $PHP_PCRE_REGEX = yes; then
-PHP_NEW_EXTENSION(pcre, pcrelib/pcre_chartables.c 
pcrelib/pcre_ucp_searchfuncs.c pcrelib/pcre_compile.c pcrelib/pcre_config.c 
pcrelib/pcre_exec.c pcrelib/pcre_fullinfo.c pcrelib/pcre_get.c 
pcrelib/pcre_globals.c pcrelib/pcre_info.c pcrelib/pcre_maketables.c 
pcrelib/pcre_newline.c pcrelib/pcre_ord2utf8.c pcrelib/pcre_refcount.c 
pcrelib/pcre_study.c pcrelib/pcre_tables.c pcrelib/pcre_try_flipped.c 
pcrelib/pcre_valid_utf8.c pcrelib/pcre_version.c pcrelib/pcre_xclass.c 
php_pcre.c, $ext_shared,,-DHAVE_CONFIG_H [EMAIL PROTECTED]@/pcrelib)
+PHP_NEW_EXTENSION(pcre, pcrelib/pcre_chartables.c 
pcrelib/pcre_ucp_searchfuncs.c pcrelib/pcre_compile.c pcrelib/pcre_config.c 
pcrelib/pcre_exec.c pcrelib/pcre_fullinfo.c pcrelib/pcre_get.c 
pcrelib/pcre_globals.c pcrelib/pcre_info.c pcrelib/pcre_maketables.c 
pcrelib/pcre_newline.c pcrelib/pcre_ord2utf8.c pcrelib/pcre_refcount.c 
pcrelib/pcre_study.c pcrelib/pcre_tables.c pcrelib/pcre_try_flipped.c 
pcrelib/pcre_valid_utf8.c pcrelib/pcre_version.c pcrelib/pcre_xclass.c 
php_pcre.c, $ext_shared,,[EMAIL PROTECTED]@/pcrelib)
 PHP_ADD_BUILD_DIR($ext_builddir/pcrelib)
 PHP_INSTALL_HEADERS([ext/pcre], [php_pcre.h pcrelib/])
 AC_DEFINE(HAVE_BUNDLED_PCRE, 1, [ ])
http://cvs.php.net/viewvc.cgi/php-src/ext/pcre/upgrade-pcre.php?r1=1.1.2.2r2=1.1.2.3diff_format=u
Index: php-src/ext/pcre/upgrade-pcre.php
diff -u php-src/ext/pcre/upgrade-pcre.php:1.1.2.2 
php-src/ext/pcre/upgrade-pcre.php:1.1.2.3
--- php-src/ext/pcre/upgrade-pcre.php:1.1.2.2   Fri Jun 15 19:09:24 2007
+++ php-src/ext/pcre/upgrade-pcre.php   Tue Sep 11 16:17:33 2007
@@ -33,10 +33,13 @@
 {
global $newpcre, $dirlen;
 
-   foreach(scandir($path) as $file) {
+   foreach (scandir($path) as $file) {
 
-   if ($file[0] === '.' || $file === 'CVS') continue;
-   if (substr_compare($file, '.lo', -3, 3) == 0 || 
substr_compare($file, '.o', -2, 2) == 0) continue;
+   if ($file[0] === '.' ||
+   $file === 'CVS' ||
+   substr_compare($file, '.lo', -3, 3) == 0 ||
+   substr_compare($file, '.loT', -4, 4) == 0 ||
+   

[PHP-CVS] cvs: php-src /ext/pcre config.w32 config0.m4 upgrade-pcre.php /ext/pcre/pcrelib dftables.c pcre_chartables.c pcre_compile.c pcre_config.c pcre_exec.c pcre_fullinfo.c pcre_get.c pcre_globals

2007-09-11 Thread Nuno Lopes
nlopess Tue Sep 11 16:19:14 2007 UTC

  Modified files:  
/php-src/ext/pcre   config.w32 config0.m4 upgrade-pcre.php 
/php-src/ext/pcre/pcrelib   dftables.c pcre_chartables.c 
pcre_compile.c pcre_config.c pcre_exec.c 
pcre_fullinfo.c pcre_get.c pcre_globals.c 
pcre_info.c pcre_maketables.c 
pcre_newline.c pcre_ord2utf8.c 
pcre_refcount.c pcre_study.c 
pcre_tables.c pcre_try_flipped.c 
pcre_ucp_searchfuncs.c pcre_valid_utf8.c 
pcre_version.c pcre_xclass.c pcregrep.c 
pcreposix.c 
  Log:
  MFB: remove HAVE_CONFIG_H
  http://cvs.php.net/viewvc.cgi/php-src/ext/pcre/config.w32?r1=1.14r2=1.15diff_format=u
Index: php-src/ext/pcre/config.w32
diff -u php-src/ext/pcre/config.w32:1.14 php-src/ext/pcre/config.w32:1.15
--- php-src/ext/pcre/config.w32:1.14Sat Sep  1 18:01:43 2007
+++ php-src/ext/pcre/config.w32 Tue Sep 11 16:19:14 2007
@@ -1,11 +1,11 @@
-// $Id: config.w32,v 1.14 2007/09/01 18:01:43 nlopess Exp $
+// $Id: config.w32,v 1.15 2007/09/11 16:19:14 nlopess Exp $
 // vim:ft=javascript
 
 ARG_WITH(pcre-regex, Perl Compatible Regular Expressions, yes);
 
 if (PHP_PCRE_REGEX == yes) {
EXTENSION(pcre, php_pcre.c, PHP_PCRE_REGEX_SHARED,
-   -DNO_RECURSE -DHAVE_CONFIG_H -Iext/pcre/pcrelib);
+   -DNO_RECURSE -Iext/pcre/pcrelib);
ADD_SOURCES(ext/pcre/pcrelib, pcre_chartables.c 
pcre_ucp_searchfuncs.c pcre_compile.c pcre_config.c pcre_exec.c pcre_fullinfo.c 
pcre_get.c pcre_globals.c pcre_info.c pcre_maketables.c pcre_newline.c 
pcre_ord2utf8.c pcre_refcount.c pcre_study.c pcre_tables.c pcre_try_flipped.c 
pcre_valid_utf8.c pcre_version.c pcre_xclass.c, pcre);
ADD_DEF_FILE(ext\\pcre\\php_pcre.def);
 
http://cvs.php.net/viewvc.cgi/php-src/ext/pcre/config0.m4?r1=1.49r2=1.50diff_format=u
Index: php-src/ext/pcre/config0.m4
diff -u php-src/ext/pcre/config0.m4:1.49 php-src/ext/pcre/config0.m4:1.50
--- php-src/ext/pcre/config0.m4:1.49Sat Sep  1 18:01:43 2007
+++ php-src/ext/pcre/config0.m4 Tue Sep 11 16:19:14 2007
@@ -1,5 +1,5 @@
 dnl
-dnl $Id: config0.m4,v 1.49 2007/09/01 18:01:43 nlopess Exp $
+dnl $Id: config0.m4,v 1.50 2007/09/11 16:19:14 nlopess Exp $
 dnl
 
 dnl By default we'll compile and link against the bundled PCRE library
@@ -11,7 +11,7 @@
 
 if test $PHP_PCRE_REGEX != no; then
   if test $PHP_PCRE_REGEX = yes; then
-PHP_NEW_EXTENSION(pcre, pcrelib/pcre_chartables.c 
pcrelib/pcre_ucp_searchfuncs.c pcrelib/pcre_compile.c pcrelib/pcre_config.c 
pcrelib/pcre_exec.c pcrelib/pcre_fullinfo.c pcrelib/pcre_get.c 
pcrelib/pcre_globals.c pcrelib/pcre_info.c pcrelib/pcre_maketables.c 
pcrelib/pcre_newline.c pcrelib/pcre_ord2utf8.c pcrelib/pcre_refcount.c 
pcrelib/pcre_study.c pcrelib/pcre_tables.c pcrelib/pcre_try_flipped.c 
pcrelib/pcre_valid_utf8.c pcrelib/pcre_version.c pcrelib/pcre_xclass.c 
php_pcre.c, $ext_shared,,-DHAVE_CONFIG_H [EMAIL PROTECTED]@/pcrelib)
+PHP_NEW_EXTENSION(pcre, pcrelib/pcre_chartables.c 
pcrelib/pcre_ucp_searchfuncs.c pcrelib/pcre_compile.c pcrelib/pcre_config.c 
pcrelib/pcre_exec.c pcrelib/pcre_fullinfo.c pcrelib/pcre_get.c 
pcrelib/pcre_globals.c pcrelib/pcre_info.c pcrelib/pcre_maketables.c 
pcrelib/pcre_newline.c pcrelib/pcre_ord2utf8.c pcrelib/pcre_refcount.c 
pcrelib/pcre_study.c pcrelib/pcre_tables.c pcrelib/pcre_try_flipped.c 
pcrelib/pcre_valid_utf8.c pcrelib/pcre_version.c pcrelib/pcre_xclass.c 
php_pcre.c, $ext_shared,,[EMAIL PROTECTED]@/pcrelib)
 PHP_ADD_BUILD_DIR($ext_builddir/pcrelib)
 PHP_INSTALL_HEADERS([ext/pcre], [php_pcre.h pcrelib/])
PHP_ADD_INCLUDE(pcrelib)
http://cvs.php.net/viewvc.cgi/php-src/ext/pcre/upgrade-pcre.php?r1=1.1r2=1.2diff_format=u
Index: php-src/ext/pcre/upgrade-pcre.php
diff -u php-src/ext/pcre/upgrade-pcre.php:1.1 
php-src/ext/pcre/upgrade-pcre.php:1.2
--- php-src/ext/pcre/upgrade-pcre.php:1.1   Thu Jun 14 19:43:41 2007
+++ php-src/ext/pcre/upgrade-pcre.php   Tue Sep 11 16:19:14 2007
@@ -33,10 +33,13 @@
 {
global $newpcre, $dirlen;
 
-   foreach(scandir($path) as $file) {
+   foreach (scandir($path) as $file) {
 
-   if ($file[0] === '.' || $file === 'CVS') continue;
-   if (substr_compare($file, '.lo', -3, 3) == 0 || 
substr_compare($file, '.o', -2, 2) == 0) continue;
+   if ($file[0] === '.' ||
+   $file === 'CVS' ||
+   substr_compare($file, '.lo', -3, 3) == 0 ||
+   substr_compare($file, '.loT', -4, 4) == 0 ||
+   substr_compare($file, '.o', -2, 2) == 0) continue;
 
$file = $path/$file;
 
@@ -58,7 +61,19 @@
die($newfile is not available any more\n);
}
 
-   copy($newfile, $file);
+   // 

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

2007-09-12 Thread Nuno Lopes
nlopess Wed Sep 12 11:42:43 2007 UTC

  Modified files:  (Branch: PHP_5_2)
/php-src/ext/standard   proc_open.c 
  Log:
  fix bug #39651: proc_open() append mode doesnt work on windows
  
http://cvs.php.net/viewvc.cgi/php-src/ext/standard/proc_open.c?r1=1.36.2.1.2.16r2=1.36.2.1.2.17diff_format=u
Index: php-src/ext/standard/proc_open.c
diff -u php-src/ext/standard/proc_open.c:1.36.2.1.2.16 
php-src/ext/standard/proc_open.c:1.36.2.1.2.17
--- php-src/ext/standard/proc_open.c:1.36.2.1.2.16  Fri Aug 17 10:42:30 2007
+++ php-src/ext/standard/proc_open.cWed Sep 12 11:42:43 2007
@@ -15,7 +15,7 @@
| Author: Wez Furlong [EMAIL PROTECTED]   |
+--+
  */
-/* $Id: proc_open.c,v 1.36.2.1.2.16 2007/08/17 10:42:30 jani Exp $ */
+/* $Id: proc_open.c,v 1.36.2.1.2.17 2007/09/12 11:42:43 nlopess Exp $ */
 
 #if 0  (defined(__linux__) || defined(sun) || defined(__IRIX__))
 # define _BSD_SOURCE   /* linux wants this when XOPEN mode is on */
@@ -677,6 +677,12 @@
 #ifdef PHP_WIN32
descriptors[ndesc].childend = 
dup_fd_as_handle(fd);
_close(fd);
+
+   /* simulate the append mode by fseeking to the 
end of the file
+   this introduces a potential race-condition, but 
it is the best we can do, though */
+   if (strchr(Z_STRVAL_PP(zmode), 'a')) {
+   
SetFilePointer(descriptors[ndesc].childend, 0, NULL, FILE_END);
+   }
 #else
descriptors[ndesc].childend = fd;
 #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_2) / NEWS

2007-09-12 Thread Nuno Lopes
nlopess Wed Sep 12 11:44:25 2007 UTC

  Modified files:  (Branch: PHP_5_2)
/php-srcNEWS 
  Log:
  BFN #39651
  
http://cvs.php.net/viewvc.cgi/php-src/NEWS?r1=1.2027.2.547.2.943r2=1.2027.2.547.2.944diff_format=u
Index: php-src/NEWS
diff -u php-src/NEWS:1.2027.2.547.2.943 php-src/NEWS:1.2027.2.547.2.944
--- php-src/NEWS:1.2027.2.547.2.943 Wed Sep 12 09:49:20 2007
+++ php-src/NEWSWed Sep 12 11:44:25 2007
@@ -1,4 +1,4 @@
-PHPNEWS
+PHP
NEWS
 |||
 ?? ??? 20??, PHP 5.2.5
 - Fixed missing brackets leading to build warning and error in the log.
@@ -44,6 +44,7 @@
   compliant wsdl). (Dmitry)
 - Fixed bug #41561 (Values set with php_admin_* in httpd.conf can be 
overwritten
   with ini_set()). (Stas, Jani)
+- Fixed bug #39651 (proc_open() append mode doesn't work on windows). (Nuno)
 
 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 /ext/standard proc_open.c

2007-09-12 Thread Nuno Lopes
nlopess Wed Sep 12 11:46:08 2007 UTC

  Modified files:  
/php-src/ext/standard   proc_open.c 
  Log:
  MFB: fix #39651
  
http://cvs.php.net/viewvc.cgi/php-src/ext/standard/proc_open.c?r1=1.58r2=1.59diff_format=u
Index: php-src/ext/standard/proc_open.c
diff -u php-src/ext/standard/proc_open.c:1.58 
php-src/ext/standard/proc_open.c:1.59
--- php-src/ext/standard/proc_open.c:1.58   Fri Aug 17 10:42:12 2007
+++ php-src/ext/standard/proc_open.cWed Sep 12 11:46:08 2007
@@ -15,7 +15,7 @@
| Author: Wez Furlong [EMAIL PROTECTED]   |
+--+
  */
-/* $Id: proc_open.c,v 1.58 2007/08/17 10:42:12 jani Exp $ */
+/* $Id: proc_open.c,v 1.59 2007/09/12 11:46:08 nlopess Exp $ */
 
 #if 0  (defined(__linux__) || defined(sun) || defined(__IRIX__))
 # define _BSD_SOURCE   /* linux wants this when XOPEN mode is on */
@@ -669,6 +669,12 @@
 #ifdef PHP_WIN32
descriptors[ndesc].childend = 
dup_fd_as_handle(fd);
_close(fd);
+
+   /* simulate the append mode by fseeking to the 
end of the file
+   this introduces a potential race-condition, but 
it is the best we can do, though */
+   if (strchr(Z_STRVAL_PP(zmode), 'a')) {
+   
SetFilePointer(descriptors[ndesc].childend, 0, NULL, FILE_END);
+   }
 #else
descriptors[ndesc].childend = fd;
 #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_2) /ext/standard/tests/file 006_basic.phpt 006_error.phpt 006_variation1.phpt 006_variation2.phpt copy_variation15.phpt copy_variation9.phpt is_executable_basic.phpt is_ex

2007-09-13 Thread Nuno Lopes
nlopess Thu Sep 13 18:24:26 2007 UTC

  Modified files:  (Branch: PHP_5_2)
/php-src/ext/standard/tests/file006_basic.phpt 006_error.phpt 
006_variation1.phpt 
006_variation2.phpt 
copy_variation15.phpt 
copy_variation9.phpt 
is_executable_basic.phpt 
is_executable_variation1.phpt 
is_executable_variation2.phpt 
is_executable_variation3.phpt 
is_readable_basic.phpt 
is_readable_variation1.phpt 
is_readable_variation2.phpt 
is_readable_variation3.phpt 
is_writable_basic.phpt 
is_writable_variation1.phpt 
is_writable_variation2.phpt 
is_writable_variation3.phpt 
mkdir_rmdir_variation1.phpt 
mkdir_rmdir_variation2.phpt 

symlink_link_linkinfo_is_link_variation6.phpt 
unlink_variation1.phpt 
  Log:
  fix skip reasons. the word 'skip' should be followed by a single space and 
doesnt need any \n at the end
  http://cvs.php.net/viewvc.cgi/php-src/ext/standard/tests/file/006_basic.phpt?r1=1.1.2.2r2=1.1.2.3diff_format=u
Index: php-src/ext/standard/tests/file/006_basic.phpt
diff -u php-src/ext/standard/tests/file/006_basic.phpt:1.1.2.2 
php-src/ext/standard/tests/file/006_basic.phpt:1.1.2.3
--- php-src/ext/standard/tests/file/006_basic.phpt:1.1.2.2  Fri Jul  6 
03:40:31 2007
+++ php-src/ext/standard/tests/file/006_basic.phpt  Thu Sep 13 18:24:26 2007
@@ -11,7 +11,7 @@
 fclose($fp);
 if(fileowner($filename) == 0) {
 unlink ($filename);
-die('skip...cannot be run as root\n');
+die('skip cannot be run as root');
 }
 
 unlink($filename);
http://cvs.php.net/viewvc.cgi/php-src/ext/standard/tests/file/006_error.phpt?r1=1.1.2.2r2=1.1.2.3diff_format=u
Index: php-src/ext/standard/tests/file/006_error.phpt
diff -u php-src/ext/standard/tests/file/006_error.phpt:1.1.2.2 
php-src/ext/standard/tests/file/006_error.phpt:1.1.2.3
--- php-src/ext/standard/tests/file/006_error.phpt:1.1.2.2  Thu Jul  5 
18:53:33 2007
+++ php-src/ext/standard/tests/file/006_error.phpt  Thu Sep 13 18:24:26 2007
@@ -11,7 +11,7 @@
 fclose($fp);
 if(fileowner($filename) == 0) {
 unlink ($filename);
-die('skip...cannot be run as root\n');
+die('skip cannot be run as root');
 }
 
 unlink($filename);
http://cvs.php.net/viewvc.cgi/php-src/ext/standard/tests/file/006_variation1.phpt?r1=1.1.2.2r2=1.1.2.3diff_format=u
Index: php-src/ext/standard/tests/file/006_variation1.phpt
diff -u php-src/ext/standard/tests/file/006_variation1.phpt:1.1.2.2 
php-src/ext/standard/tests/file/006_variation1.phpt:1.1.2.3
--- php-src/ext/standard/tests/file/006_variation1.phpt:1.1.2.2 Fri Jul  6 
03:40:31 2007
+++ php-src/ext/standard/tests/file/006_variation1.phpt Thu Sep 13 18:24:26 2007
@@ -11,7 +11,7 @@
 fclose($fp);
 if(fileowner($filename) == 0) {
 unlink ($filename);
-die('skip...cannot be run as root\n');
+die('skip cannot be run as root');
 }
 
 unlink($filename);
http://cvs.php.net/viewvc.cgi/php-src/ext/standard/tests/file/006_variation2.phpt?r1=1.1.2.2r2=1.1.2.3diff_format=u
Index: php-src/ext/standard/tests/file/006_variation2.phpt
diff -u php-src/ext/standard/tests/file/006_variation2.phpt:1.1.2.2 
php-src/ext/standard/tests/file/006_variation2.phpt:1.1.2.3
--- php-src/ext/standard/tests/file/006_variation2.phpt:1.1.2.2 Fri Jul  6 
03:40:31 2007
+++ php-src/ext/standard/tests/file/006_variation2.phpt Thu Sep 13 18:24:26 2007
@@ -11,7 +11,7 @@
 fclose($fp);
 if(fileowner($filename) == 0) {
 unlink ($filename);
-die('skip...cannot be run as root\n');
+die('skip cannot be run as root');
 }
 
 unlink($filename);
http://cvs.php.net/viewvc.cgi/php-src/ext/standard/tests/file/copy_variation15.phpt?r1=1.1.2.4r2=1.1.2.5diff_format=u
Index: php-src/ext/standard/tests/file/copy_variation15.phpt
diff -u php-src/ext/standard/tests/file/copy_variation15.phpt:1.1.2.4 
php-src/ext/standard/tests/file/copy_variation15.phpt:1.1.2.5
--- php-src/ext/standard/tests/file/copy_variation15.phpt:1.1.2.4   Tue Sep 
 4 08:37:51 2007
+++ php-src/ext/standard/tests/file/copy_variation15.phpt   Thu Sep 13 
18:24:26 2007
@@ -10,7 +10,7 @@
 fclose($fp);
 if(fileowner($filename) == 0) {
 unlink ($filename);
-die('skip...cannot be run as root\n');
+

[PHP-CVS] cvs: php-src /ext/standard/tests/file 006_basic.phpt 006_error.phpt 006_variation1.phpt 006_variation2.phpt copy_variation15.phpt copy_variation9.phpt is_executable_basic.phpt is_executable_

2007-09-13 Thread Nuno Lopes
nlopess Thu Sep 13 18:26:12 2007 UTC

  Modified files:  
/php-src/ext/standard/tests/file006_basic.phpt 006_error.phpt 
006_variation1.phpt 
006_variation2.phpt 
copy_variation15.phpt 
copy_variation9.phpt 
is_executable_basic.phpt 
is_executable_variation1.phpt 
is_executable_variation2.phpt 
is_executable_variation3.phpt 
is_readable_basic.phpt 
is_readable_variation1.phpt 
is_readable_variation2.phpt 
is_readable_variation3.phpt 
is_writable_basic.phpt 
mkdir_rmdir_variation1.phpt 
mkdir_rmdir_variation2.phpt 

symlink_link_linkinfo_is_link_variation6.phpt 
unlink_variation1.phpt 
  Log:
  MFB: fix skip reasons
  http://cvs.php.net/viewvc.cgi/php-src/ext/standard/tests/file/006_basic.phpt?r1=1.3r2=1.4diff_format=u
Index: php-src/ext/standard/tests/file/006_basic.phpt
diff -u php-src/ext/standard/tests/file/006_basic.phpt:1.3 
php-src/ext/standard/tests/file/006_basic.phpt:1.4
--- php-src/ext/standard/tests/file/006_basic.phpt:1.3  Fri Jul  6 03:24:27 2007
+++ php-src/ext/standard/tests/file/006_basic.phpt  Thu Sep 13 18:26:12 2007
@@ -11,7 +11,7 @@
 fclose($fp);
 if(fileowner($filename) == 0) {
 unlink ($filename);
-die('skip...cannot be run as root\n');
+die('skip cannot be run as root');
 }
 
 unlink($filename);
http://cvs.php.net/viewvc.cgi/php-src/ext/standard/tests/file/006_error.phpt?r1=1.3r2=1.4diff_format=u
Index: php-src/ext/standard/tests/file/006_error.phpt
diff -u php-src/ext/standard/tests/file/006_error.phpt:1.3 
php-src/ext/standard/tests/file/006_error.phpt:1.4
--- php-src/ext/standard/tests/file/006_error.phpt:1.3  Thu Jul  5 18:59:20 2007
+++ php-src/ext/standard/tests/file/006_error.phpt  Thu Sep 13 18:26:12 2007
@@ -11,7 +11,7 @@
 fclose($fp);
 if(fileowner($filename) == 0) {
 unlink ($filename);
-die('skip...cannot be run as root\n');
+die('skip cannot be run as root');
 }
 
 unlink($filename);
http://cvs.php.net/viewvc.cgi/php-src/ext/standard/tests/file/006_variation1.phpt?r1=1.3r2=1.4diff_format=u
Index: php-src/ext/standard/tests/file/006_variation1.phpt
diff -u php-src/ext/standard/tests/file/006_variation1.phpt:1.3 
php-src/ext/standard/tests/file/006_variation1.phpt:1.4
--- php-src/ext/standard/tests/file/006_variation1.phpt:1.3 Fri Jul  6 
03:24:27 2007
+++ php-src/ext/standard/tests/file/006_variation1.phpt Thu Sep 13 18:26:12 2007
@@ -11,7 +11,7 @@
 fclose($fp);
 if(fileowner($filename) == 0) {
 unlink ($filename);
-die('skip...cannot be run as root\n');
+die('skip cannot be run as root');
 }
 
 unlink($filename);
http://cvs.php.net/viewvc.cgi/php-src/ext/standard/tests/file/006_variation2.phpt?r1=1.3r2=1.4diff_format=u
Index: php-src/ext/standard/tests/file/006_variation2.phpt
diff -u php-src/ext/standard/tests/file/006_variation2.phpt:1.3 
php-src/ext/standard/tests/file/006_variation2.phpt:1.4
--- php-src/ext/standard/tests/file/006_variation2.phpt:1.3 Fri Jul  6 
03:24:27 2007
+++ php-src/ext/standard/tests/file/006_variation2.phpt Thu Sep 13 18:26:12 2007
@@ -11,7 +11,7 @@
 fclose($fp);
 if(fileowner($filename) == 0) {
 unlink ($filename);
-die('skip...cannot be run as root\n');
+die('skip cannot be run as root');
 }
 
 unlink($filename);
http://cvs.php.net/viewvc.cgi/php-src/ext/standard/tests/file/copy_variation15.phpt?r1=1.5r2=1.6diff_format=u
Index: php-src/ext/standard/tests/file/copy_variation15.phpt
diff -u php-src/ext/standard/tests/file/copy_variation15.phpt:1.5 
php-src/ext/standard/tests/file/copy_variation15.phpt:1.6
--- php-src/ext/standard/tests/file/copy_variation15.phpt:1.5   Tue Sep  4 
08:39:40 2007
+++ php-src/ext/standard/tests/file/copy_variation15.phpt   Thu Sep 13 
18:26:12 2007
@@ -10,7 +10,7 @@
 fclose($fp);
 if(fileowner($filename) == 0) {
 unlink ($filename);
-die('skip...cannot be run as root\n');
+die('skip cannot be run as root');
 }
 unlink($filename);
 ?
http://cvs.php.net/viewvc.cgi/php-src/ext/standard/tests/file/copy_variation9.phpt?r1=1.5r2=1.6diff_format=u
Index: php-src/ext/standard/tests/file/copy_variation9.phpt
diff -u php-src/ext/standard/tests/file/copy_variation9.phpt:1.5 
php-src/ext/standard/tests/file/copy_variation9.phpt:1.6
--- php-src/ext/standard/tests/file/copy_variation9.phpt:1.5

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

2007-09-13 Thread Nuno Lopes
nlopess Thu Sep 13 18:55:28 2007 UTC

  Modified files:  (Branch: PHP_5_2)
/php-src/ext/standard/tests/filebug41655_2.phpt 
  Log:
  fix test expected output
  
http://cvs.php.net/viewvc.cgi/php-src/ext/standard/tests/file/bug41655_2.phpt?r1=1.1.4.2r2=1.1.4.3diff_format=u
Index: php-src/ext/standard/tests/file/bug41655_2.phpt
diff -u php-src/ext/standard/tests/file/bug41655_2.phpt:1.1.4.2 
php-src/ext/standard/tests/file/bug41655_2.phpt:1.1.4.3
--- php-src/ext/standard/tests/file/bug41655_2.phpt:1.1.4.2 Fri Jun 22 
12:35:41 2007
+++ php-src/ext/standard/tests/file/bug41655_2.phpt Thu Sep 13 18:55:28 2007
@@ -11,6 +11,7 @@
 --EXPECTF--
 Array
 (
-[%d] = %sbug41655_1.phpt
-[%d] = %sbug41655_2.phpt
+[0] = %sbug41655_1.phpt
+[1] = %sbug41655_2.php
+[2] = %sbug41655_2.phpt
 )

-- 
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/file bug41655_2.phpt

2007-09-13 Thread Nuno Lopes
nlopess Thu Sep 13 18:56:21 2007 UTC

  Modified files:  
/php-src/ext/standard/tests/filebug41655_2.phpt 
  Log:
  MFB: fix expected output
  
http://cvs.php.net/viewvc.cgi/php-src/ext/standard/tests/file/bug41655_2.phpt?r1=1.2r2=1.3diff_format=u
Index: php-src/ext/standard/tests/file/bug41655_2.phpt
diff -u php-src/ext/standard/tests/file/bug41655_2.phpt:1.2 
php-src/ext/standard/tests/file/bug41655_2.phpt:1.3
--- php-src/ext/standard/tests/file/bug41655_2.phpt:1.2 Fri Jun 22 12:36:55 2007
+++ php-src/ext/standard/tests/file/bug41655_2.phpt Thu Sep 13 18:56:21 2007
@@ -11,6 +11,7 @@
 --EXPECTF--
 Array
 (
-[%d] = %sbug41655_1.phpt
-[%d] = %sbug41655_2.phpt
+[0] = %sbug41655_1.phpt
+[1] = %sbug41655_2.php
+[2] = %sbug41655_2.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) /tests/lang bug20175.phpt

2007-09-13 Thread Nuno Lopes
nlopess Thu Sep 13 19:30:19 2007 UTC

  Modified files:  (Branch: PHP_5_2)
/php-src/tests/lang bug20175.phpt 
  Log:
  fix expected output
  
http://cvs.php.net/viewvc.cgi/php-src/tests/lang/bug20175.phpt?r1=1.8r2=1.8.4.1diff_format=u
Index: php-src/tests/lang/bug20175.phpt
diff -u php-src/tests/lang/bug20175.phpt:1.8 
php-src/tests/lang/bug20175.phpt:1.8.4.1
--- php-src/tests/lang/bug20175.phpt:1.8Thu May  5 17:37:25 2005
+++ php-src/tests/lang/bug20175.phptThu Sep 13 19:30:19 2007
@@ -139,6 +139,7 @@
 print $oop_tester-oop_static().\n;
 ?
 --EXPECTF--
+Strict Standards: Assigning the return value of new by reference is deprecated 
in %s.php on line %d
 %s
 foo_static()
 foo_global()

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



[PHP-CVS] cvs: php-src /tests/lang bug20175.phpt

2007-09-13 Thread Nuno Lopes
nlopess Thu Sep 13 19:31:08 2007 UTC

  Modified files:  
/php-src/tests/lang bug20175.phpt 
  Log:
  MFB: fix expected output
  
http://cvs.php.net/viewvc.cgi/php-src/tests/lang/bug20175.phpt?r1=1.8r2=1.9diff_format=u
Index: php-src/tests/lang/bug20175.phpt
diff -u php-src/tests/lang/bug20175.phpt:1.8 
php-src/tests/lang/bug20175.phpt:1.9
--- php-src/tests/lang/bug20175.phpt:1.8Thu May  5 17:37:25 2005
+++ php-src/tests/lang/bug20175.phptThu Sep 13 19:31:08 2007
@@ -139,6 +139,7 @@
 print $oop_tester-oop_static().\n;
 ?
 --EXPECTF--
+Strict Standards: Assigning the return value of new by reference is deprecated 
in %s.php on line %d
 %s
 foo_static()
 foo_global()

-- 
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/strings strtolower.phpt

2007-09-13 Thread Nuno Lopes
nlopess Thu Sep 13 19:46:49 2007 UTC

  Modified files:  (Branch: PHP_5_2)
/php-src/ext/standard/tests/strings strtolower.phpt 
  Log:
  attemp to set locale if it exists. fix skip condition
  
http://cvs.php.net/viewvc.cgi/php-src/ext/standard/tests/strings/strtolower.phpt?r1=1.1.2.1r2=1.1.2.2diff_format=u
Index: php-src/ext/standard/tests/strings/strtolower.phpt
diff -u php-src/ext/standard/tests/strings/strtolower.phpt:1.1.2.1 
php-src/ext/standard/tests/strings/strtolower.phpt:1.1.2.2
--- php-src/ext/standard/tests/strings/strtolower.phpt:1.1.2.1  Fri Aug 10 
03:03:49 2007
+++ php-src/ext/standard/tests/strings/strtolower.phpt  Thu Sep 13 19:46:49 2007
@@ -2,8 +2,8 @@
 Test strtolower() function
 --SKIPIF--
 ?php
-if( (substr(PHP_OS, 0, 5) != Linux)  (setlocale(LC_CTYPE, ) != 
en-US.UTF-8) )
-  die('skip Run only on Linux with locale as en-US.UTF-8');
+if (!setlocale(LC_ALL, 'en-US.UTF-8'))
+  die('skip need en-US.UTF-8 locale');
 ?
 --FILE--
 ?php
@@ -13,6 +13,8 @@
  Returns string with all alphabetic characters converted to lowercase.
 */
 
+setlocale(LC_ALL, 'en-US.UTF-8');
+
 echo *** Testing strtolower() with all 256 chars ***\n;
 for ($i=0; $i=255; $i++){
   $char = chr($i);

-- 
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/strings strtolower.phpt

2007-09-13 Thread Nuno Lopes
nlopess Thu Sep 13 19:48:58 2007 UTC

  Modified files:  
/php-src/ext/standard/tests/strings strtolower.phpt 
  Log:
  MFB
  
http://cvs.php.net/viewvc.cgi/php-src/ext/standard/tests/strings/strtolower.phpt?r1=1.2r2=1.3diff_format=u
Index: php-src/ext/standard/tests/strings/strtolower.phpt
diff -u php-src/ext/standard/tests/strings/strtolower.phpt:1.2 
php-src/ext/standard/tests/strings/strtolower.phpt:1.3
--- php-src/ext/standard/tests/strings/strtolower.phpt:1.2  Fri Aug 10 
03:05:00 2007
+++ php-src/ext/standard/tests/strings/strtolower.phpt  Thu Sep 13 19:48:58 2007
@@ -2,8 +2,8 @@
 Test strtolower() function
 --SKIPIF--
 ?php
-if( (substr(PHP_OS, 0, 5) != Linux)  (@setlocale(LC_CTYPE, ) != 
en-US.UTF-8) )
-  die('skip Run only on Linux with locale as en-US.UTF-8');
+if ([EMAIL PROTECTED](LC_ALL, 'en-US.UTF-8'))
+  die('skip need en-US.UTF-8 locale');
 ?
 --FILE--
 ?php
@@ -13,6 +13,8 @@
  Returns string with all alphabetic characters converted to lowercase.
 */
 
+setlocale(LC_ALL, 'en-US.UTF-8');
+
 echo *** Testing strtolower() with all 256 chars ***\n;
 for ($i=0; $i=255; $i++){
   $char = chr($i);

-- 
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/strings strtoupper1.phpt

2007-09-13 Thread Nuno Lopes
nlopess Thu Sep 13 19:52:45 2007 UTC

  Modified files:  
/php-src/ext/standard/tests/strings strtoupper1.phpt 
  Log:
  MFB
  
http://cvs.php.net/viewvc.cgi/php-src/ext/standard/tests/strings/strtoupper1.phpt?r1=1.2r2=1.3diff_format=u
Index: php-src/ext/standard/tests/strings/strtoupper1.phpt
diff -u php-src/ext/standard/tests/strings/strtoupper1.phpt:1.2 
php-src/ext/standard/tests/strings/strtoupper1.phpt:1.3
--- php-src/ext/standard/tests/strings/strtoupper1.phpt:1.2 Fri Aug 10 
03:05:00 2007
+++ php-src/ext/standard/tests/strings/strtoupper1.phpt Thu Sep 13 19:52:45 2007
@@ -2,8 +2,8 @@
 Test strtoupper() function
 --SKIPIF--
 ?php
-if( (substr(PHP_OS, 0, 5) != Linux)  (@setlocale(LC_CTYPE, ) != 
en-US.UTF-8) )
-  die('skip Run only on Linux with locale as en-US.UTF-8');
+if ([EMAIL PROTECTED](LC_ALL, 'en-US.UTF-8'))
+  die('skip need en-US.UTF-8 locale');
 ?
 --FILE--
 ?php
@@ -13,6 +13,8 @@
  Returns string with all alphabetic characters converted to uppercase
 */ 
 
+setlocale(LC_ALL, 'en-US.UTF-8');
+
 echo *** Testing strtoupper() with all 256 chars ***\n;
 for ($i=0; $i=255; $i++){
   $char = chr($i);

-- 
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/strings strtoupper1.phpt

2007-09-13 Thread Nuno Lopes
nlopess Thu Sep 13 19:51:34 2007 UTC

  Modified files:  (Branch: PHP_5_2)
/php-src/ext/standard/tests/strings strtoupper1.phpt 
  Log:
  attemp to set locale if it exists. fix skip condition
  
http://cvs.php.net/viewvc.cgi/php-src/ext/standard/tests/strings/strtoupper1.phpt?r1=1.1.2.1r2=1.1.2.2diff_format=u
Index: php-src/ext/standard/tests/strings/strtoupper1.phpt
diff -u php-src/ext/standard/tests/strings/strtoupper1.phpt:1.1.2.1 
php-src/ext/standard/tests/strings/strtoupper1.phpt:1.1.2.2
--- php-src/ext/standard/tests/strings/strtoupper1.phpt:1.1.2.1 Fri Aug 10 
03:03:49 2007
+++ php-src/ext/standard/tests/strings/strtoupper1.phpt Thu Sep 13 19:51:34 2007
@@ -2,8 +2,8 @@
 Test strtoupper() function
 --SKIPIF--
 ?php
-if( (substr(PHP_OS, 0, 5) != Linux)  (setlocale(LC_CTYPE, ) != 
en-US.UTF-8) )
-  die('skip Run only on Linux with locale as en-US.UTF-8');
+if ([EMAIL PROTECTED](LC_ALL, 'en-US.UTF-8'))
+  die('skip need en-US.UTF-8 locale');
 ?
 --FILE--
 ?php
@@ -13,6 +13,8 @@
  Returns string with all alphabetic characters converted to uppercase
 */ 
 
+setlocale(LC_ALL, 'en-US.UTF-8');
+
 echo *** Testing strtoupper() with all 256 chars ***\n;
 for ($i=0; $i=255; $i++){
   $char = chr($i);

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

2007-09-13 Thread Nuno Lopes
nlopess Thu Sep 13 19:58:26 2007 UTC

  Modified files:  (Branch: PHP_5_2)
/php-src/ext/date/tests bug35885.phpt 
  Log:
  fix test, particularly when running with valgrind, bacause it may take more 
than one second to execute both instructions and thus get different dates
  
http://cvs.php.net/viewvc.cgi/php-src/ext/date/tests/bug35885.phpt?r1=1.1.2.2.2.1r2=1.1.2.2.2.2diff_format=u
Index: php-src/ext/date/tests/bug35885.phpt
diff -u php-src/ext/date/tests/bug35885.phpt:1.1.2.2.2.1 
php-src/ext/date/tests/bug35885.phpt:1.1.2.2.2.2
--- php-src/ext/date/tests/bug35885.phpt:1.1.2.2.2.1Wed Apr 11 22:34:48 2007
+++ php-src/ext/date/tests/bug35885.phptThu Sep 13 19:58:26 2007
@@ -4,8 +4,9 @@
 ?php
 date_default_timezone_set(UTC);
 
-$ts = date(DATE_ISO8601, strtotime('NOW'));
-$ts2 = date(DATE_ISO8601, time());
+$time = time();
+$ts = date(DATE_ISO8601, strtotime('NOW', $time));
+$ts2 = date(DATE_ISO8601, $time);
 
 $res = ($ts == $ts2);
 var_dump($res);

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



[PHP-CVS] cvs: php-src /ext/date/tests bug35885.phpt

2007-09-13 Thread Nuno Lopes
nlopess Thu Sep 13 19:58:53 2007 UTC

  Modified files:  
/php-src/ext/date/tests bug35885.phpt 
  Log:
  MFB
  
http://cvs.php.net/viewvc.cgi/php-src/ext/date/tests/bug35885.phpt?r1=1.2r2=1.3diff_format=u
Index: php-src/ext/date/tests/bug35885.phpt
diff -u php-src/ext/date/tests/bug35885.phpt:1.2 
php-src/ext/date/tests/bug35885.phpt:1.3
--- php-src/ext/date/tests/bug35885.phpt:1.2Wed Apr 11 22:35:25 2007
+++ php-src/ext/date/tests/bug35885.phptThu Sep 13 19:58:53 2007
@@ -4,8 +4,9 @@
 ?php
 date_default_timezone_set(UTC);
 
-$ts = date(DATE_ISO8601, strtotime('NOW'));
-$ts2 = date(DATE_ISO8601, time());
+$time = time();
+$ts = date(DATE_ISO8601, strtotime('NOW', $time));
+$ts2 = date(DATE_ISO8601, $time);
 
 $res = ($ts == $ts2);
 var_dump($res);

-- 
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/general_functions bug32647.phpt

2007-09-14 Thread Nuno Lopes
nlopess Fri Sep 14 15:04:19 2007 UTC

  Modified files:  (Branch: PHP_5_2)
/php-src/ext/standard/tests/general_functions   bug32647.phpt 
  Log:
  fix expected output
  
http://cvs.php.net/viewvc.cgi/php-src/ext/standard/tests/general_functions/bug32647.phpt?r1=1.1.6.1r2=1.1.6.1.2.1diff_format=u
Index: php-src/ext/standard/tests/general_functions/bug32647.phpt
diff -u php-src/ext/standard/tests/general_functions/bug32647.phpt:1.1.6.1 
php-src/ext/standard/tests/general_functions/bug32647.phpt:1.1.6.1.2.1
--- php-src/ext/standard/tests/general_functions/bug32647.phpt:1.1.6.1  Fri Dec 
16 22:19:02 2005
+++ php-src/ext/standard/tests/general_functions/bug32647.phpt  Fri Sep 14 
15:04:19 2007
@@ -43,8 +43,12 @@
 
 Warning: register_shutdown_function(): Invalid shutdown callback 'Array' 
passed in %s on line %d
 
+Warning: register_shutdown_function(): Invalid shutdown callback 'bar::foo' 
passed in %s on line %d
+
 Warning: register_shutdown_function(): Invalid shutdown callback 'Array' 
passed in %s on line %d
 
+Warning: register_shutdown_function(): Invalid shutdown callback 'bar' passed 
in %s on line %d
+
 Strict Standards: Non-static method bar::barfoo() cannot be called statically 
in %sbug32647.php on line %d
 
 Warning: register_shutdown_function(): Invalid shutdown callback 'bar::foobar' 
passed in %sbug32647.php on line %d

-- 
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/general_functions bug32647.phpt

2007-09-14 Thread Nuno Lopes
nlopess Fri Sep 14 15:04:46 2007 UTC

  Modified files:  
/php-src/ext/standard/tests/general_functions   bug32647.phpt 
  Log:
  MFB: fix expected output
  
http://cvs.php.net/viewvc.cgi/php-src/ext/standard/tests/general_functions/bug32647.phpt?r1=1.2r2=1.3diff_format=u
Index: php-src/ext/standard/tests/general_functions/bug32647.phpt
diff -u php-src/ext/standard/tests/general_functions/bug32647.phpt:1.2 
php-src/ext/standard/tests/general_functions/bug32647.phpt:1.3
--- php-src/ext/standard/tests/general_functions/bug32647.phpt:1.2  Fri Dec 
16 23:21:38 2005
+++ php-src/ext/standard/tests/general_functions/bug32647.phpt  Fri Sep 14 
15:04:46 2007
@@ -43,8 +43,12 @@
 
 Warning: register_shutdown_function(): Invalid shutdown callback 'Array' 
passed in %s on line %d
 
+Warning: register_shutdown_function(): Invalid shutdown callback 'bar::foo' 
passed in %s on line %d
+
 Warning: register_shutdown_function(): Invalid shutdown callback 'Array' 
passed in %s on line %d
 
+Warning: register_shutdown_function(): Invalid shutdown callback 'bar' passed 
in %s on line %d
+
 Strict Standards: Non-static method bar::barfoo() cannot be called statically 
in %sbug32647.php on line %d
 
 Warning: register_shutdown_function(): Invalid shutdown callback 'bar::foobar' 
passed in %sbug32647.php on line %d

-- 
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) / run-tests.php /ext/bz2/tests 005.phpt /ext/standard/tests/general_functions phpcredits.phpt phpinfo.phpt /ext/standard/tests/strings sha1.phpt /ext/zlib/tests 005

2007-09-14 Thread Nuno Lopes
nlopess Fri Sep 14 15:28:04 2007 UTC

  Modified files:  (Branch: PHP_5_2)
/php-srcrun-tests.php 
/php-src/ext/bz2/tests  005.phpt 
/php-src/ext/standard/tests/general_functions   phpcredits.phpt 
phpinfo.phpt 
/php-src/ext/standard/tests/strings sha1.phpt 
/php-src/ext/zlib/tests 005.phpt 006.phpt 
  Log:
  changes to run-tests.php:
  - change %s to %a
  - make %s = [^\r\n]+
  - fix tests accordingly
  
http://cvs.php.net/viewvc.cgi/php-src/run-tests.php?r1=1.226.2.37.2.34r2=1.226.2.37.2.35diff_format=u
Index: php-src/run-tests.php
diff -u php-src/run-tests.php:1.226.2.37.2.34 
php-src/run-tests.php:1.226.2.37.2.35
--- php-src/run-tests.php:1.226.2.37.2.34   Tue Jul 31 21:29:21 2007
+++ php-src/run-tests.php   Fri Sep 14 15:28:03 2007
@@ -23,7 +23,7 @@
+--+
  */
 
-/* $Id: run-tests.php,v 1.226.2.37.2.34 2007/07/31 21:29:21 jani Exp $ */
+/* $Id: run-tests.php,v 1.226.2.37.2.35 2007/09/14 15:28:03 nlopess Exp $ */
 
 /* Sanity check to ensure that pcre extension needed by this script is 
available.
  * In the event it is not, print a nice error message indicating that this 
script will
@@ -399,7 +399,7 @@
$html_output = is_resource($html_file);
break;
case '--version':
-   echo '$Revision: 1.226.2.37.2.34 
$'.\n;
+   echo '$Revision: 1.226.2.37.2.35 
$'.\n;
exit(1);
 
case 'u':
@@ -1486,14 +1486,15 @@
if (isset($section_text['EXPECTF'])) {
$wanted_re = preg_quote($wanted_re, '/');
// Stick to basics
-   $wanted_re = str_replace(%e, '\\' . 
DIRECTORY_SEPARATOR, $wanted_re);
-   $wanted_re = str_replace(%s, .+?, $wanted_re); 
//not greedy
-   $wanted_re = str_replace(%w, \s*, $wanted_re);
-   $wanted_re = str_replace(%i, [+\-]?[0-9]+, 
$wanted_re);
-   $wanted_re = str_replace(%d, [0-9]+, $wanted_re);
-   $wanted_re = str_replace(%x, [0-9a-fA-F]+, 
$wanted_re);
-   $wanted_re = str_replace(%f, 
[+\-]?\.?[0-9]+\.?[0-9]*(E-?[0-9]+)?, $wanted_re);
-   $wanted_re = str_replace(%c, ., $wanted_re);
+   $wanted_re = str_replace('%e', '\\' . 
DIRECTORY_SEPARATOR, $wanted_re);
+   $wanted_re = str_replace('%s', '[^\r\n]+', $wanted_re);
+   $wanted_re = str_replace('%a', '.+', $wanted_re);
+   $wanted_re = str_replace('%w', '\s*', $wanted_re);
+   $wanted_re = str_replace('%i', '[+-]?\d+', $wanted_re);
+   $wanted_re = str_replace('%d', '\d+', $wanted_re);
+   $wanted_re = str_replace('%x', '[0-9a-fA-F]+', 
$wanted_re);
+   $wanted_re = str_replace('%f', 
'[+-]?\.?\d+\.?\d*(?:E-?\d+)?', $wanted_re);
+   $wanted_re = str_replace('%c', '.', $wanted_re);
// %f allows two points -.0.0 but that is the best 
*simple* expression
}
 /* DEBUG YOUR REGEX HERE
http://cvs.php.net/viewvc.cgi/php-src/ext/bz2/tests/005.phpt?r1=1.1.2.1r2=1.1.2.2diff_format=u
Index: php-src/ext/bz2/tests/005.phpt
diff -u php-src/ext/bz2/tests/005.phpt:1.1.2.1 
php-src/ext/bz2/tests/005.phpt:1.1.2.2
--- php-src/ext/bz2/tests/005.phpt:1.1.2.1  Mon Jun 26 22:17:18 2006
+++ php-src/ext/bz2/tests/005.phpt  Fri Sep 14 15:28:03 2007
@@ -37,10 +37,10 @@
 
 echo Done\n;
 ?
---EXPECTF--
+--EXPECTF--
 Warning: Wrong parameter count for bzcompress() in %s on line %d
 NULL
-string(%d) BZ%s
+string(%d) BZ%a
 int(-2)
 int(-2)
 int(-2)
http://cvs.php.net/viewvc.cgi/php-src/ext/standard/tests/general_functions/phpcredits.phpt?r1=1.1.2.1r2=1.1.2.2diff_format=u
Index: php-src/ext/standard/tests/general_functions/phpcredits.phpt
diff -u php-src/ext/standard/tests/general_functions/phpcredits.phpt:1.1.2.1 
php-src/ext/standard/tests/general_functions/phpcredits.phpt:1.1.2.2
--- php-src/ext/standard/tests/general_functions/phpcredits.phpt:1.1.2.1
Fri Nov 24 20:18:54 2006
+++ php-src/ext/standard/tests/general_functions/phpcredits.phptFri Sep 
14 15:28:03 2007
@@ -17,28 +17,28 @@
 PHP Credits
 
 PHP Group
-%s
+%a
 
 Language Design  Concept
-%s
+%a
 
 %wPHP %d Authors%w
-%s
+%a
 
 %wSAPI Modules%w
-%s
+%a
 
 %wModule Authors%w
-%s
+%a
 
 %wPHP Documentation%w
-%s
+%a
 
 PHP Quality Assurance Team
-%s
+%a
 
 PHP Website Team
-%s
+%a
 bool(true)
 
 Warning: phpcredits() expects parameter 1 to be long, array given in 
%sphpcredits.php on line 4
@@ -50,5 +50,5 @@
 PHP 

[PHP-CVS] cvs: php-src / run-tests.php /ext/bz2/tests 005.phpt /ext/standard/tests/general_functions phpcredits.phpt phpinfo.phpt /ext/standard/tests/strings sha1.phpt /ext/zlib/tests 005.phpt 006

2007-09-14 Thread Nuno Lopes
nlopess Fri Sep 14 15:36:29 2007 UTC

  Modified files:  
/php-srcrun-tests.php 
/php-src/ext/bz2/tests  005.phpt 
/php-src/ext/standard/tests/general_functions   phpcredits.phpt 
phpinfo.phpt 
/php-src/ext/standard/tests/strings sha1.phpt 
/php-src/ext/zlib/tests 005.phpt 006.phpt 
  Log:
  MFB: change run-tests.php to add %a
  
http://cvs.php.net/viewvc.cgi/php-src/run-tests.php?r1=1.329r2=1.330diff_format=u
Index: php-src/run-tests.php
diff -u php-src/run-tests.php:1.329 php-src/run-tests.php:1.330
--- php-src/run-tests.php:1.329 Tue Jul 31 21:29:11 2007
+++ php-src/run-tests.php   Fri Sep 14 15:36:29 2007
@@ -24,7 +24,7 @@
+--+
  */
 
-/* $Id: run-tests.php,v 1.329 2007/07/31 21:29:11 jani Exp $ */
+/* $Id: run-tests.php,v 1.330 2007/09/14 15:36:29 nlopess Exp $ */
 
 /* Sanity check to ensure that pcre extension needed by this script is 
available.
  * In the event it is not, print a nice error message indicating that this 
script will
@@ -407,7 +407,7 @@
$html_output = is_resource($html_file);
break;
case '--version':
-   echo '$Revision: 1.329 $'.\n;
+   echo '$Revision: 1.330 $'.\n;
exit(1);
default:
echo Illegal switch specified!\n;
@@ -1550,14 +1550,15 @@
if (isset($section_text['EXPECTF'])) {
$wanted_re = preg_quote($wanted_re, '/');
// Stick to basics
-   $wanted_re = str_replace(%e, '\\' . 
DIRECTORY_SEPARATOR, $wanted_re);
-   $wanted_re = str_replace(%s, .+?, $wanted_re); 
//not greedy
-   $wanted_re = str_replace(%w, \s*, $wanted_re);
-   $wanted_re = str_replace(%i, [+\-]?[0-9]+, 
$wanted_re);
-   $wanted_re = str_replace(%d, [0-9]+, $wanted_re);
-   $wanted_re = str_replace(%x, [0-9a-fA-F]+, 
$wanted_re);
-   $wanted_re = str_replace(%f, 
[+\-]?\.?[0-9]+\.?[0-9]*(E-?[0-9]+)?, $wanted_re);
-   $wanted_re = str_replace(%c, ., $wanted_re);
+   $wanted_re = str_replace('%e', '\\' . 
DIRECTORY_SEPARATOR, $wanted_re);
+   $wanted_re = str_replace('%s', '[^\r\n]+', $wanted_re);
+   $wanted_re = str_replace('%a', '.+', $wanted_re);
+   $wanted_re = str_replace('%w', '\s*', $wanted_re);
+   $wanted_re = str_replace('%i', '[+-]?\d+', $wanted_re);
+   $wanted_re = str_replace('%d', '\d+', $wanted_re);
+   $wanted_re = str_replace('%x', '[0-9a-fA-F]+', 
$wanted_re);
+   $wanted_re = str_replace('%f', 
'[+-]?\.?\d+\.?\d*(?:E-?\d+)?', $wanted_re);
+   $wanted_re = str_replace('%c', '.', $wanted_re);
// %f allows two points -.0.0 but that is the best 
*simple* expression
}
 /* DEBUG YOUR REGEX HERE
http://cvs.php.net/viewvc.cgi/php-src/ext/bz2/tests/005.phpt?r1=1.4r2=1.5diff_format=u
Index: php-src/ext/bz2/tests/005.phpt
diff -u php-src/ext/bz2/tests/005.phpt:1.4 php-src/ext/bz2/tests/005.phpt:1.5
--- php-src/ext/bz2/tests/005.phpt:1.4  Sat Oct  7 23:42:43 2006
+++ php-src/ext/bz2/tests/005.phpt  Fri Sep 14 15:36:29 2007
@@ -38,10 +38,10 @@
 
 echo Done\n;
 ?
---EXPECTF--
+--EXPECTF--
 Warning: bzcompress() expects at least 1 parameter, 0 given in %s on line %d
 NULL
-string(%d) BZ%s
+string(%d) BZ%a
 int(-2)
 int(-2)
 int(-2)
@@ -73,7 +73,7 @@
 --UEXPECTF--
 Warning: bzcompress() expects at least 1 parameter, 0 given in %s on line %d
 NULL
-unicode(%d) BZ%s
+unicode(%d) BZ%a
 int(-2)
 int(-2)
 int(-2)
http://cvs.php.net/viewvc.cgi/php-src/ext/standard/tests/general_functions/phpcredits.phpt?r1=1.3r2=1.4diff_format=u
Index: php-src/ext/standard/tests/general_functions/phpcredits.phpt
diff -u php-src/ext/standard/tests/general_functions/phpcredits.phpt:1.3 
php-src/ext/standard/tests/general_functions/phpcredits.phpt:1.4
--- php-src/ext/standard/tests/general_functions/phpcredits.phpt:1.3Wed Feb 
14 19:20:15 2007
+++ php-src/ext/standard/tests/general_functions/phpcredits.phptFri Sep 
14 15:36:29 2007
@@ -17,28 +17,28 @@
 PHP Credits
 
 PHP Group
-%s
+%a
 
 Language Design  Concept
-%s
+%a
 
 %wPHP Authors%w
-%s
+%a
 
 %wSAPI Modules%w
-%s
+%a
 
 %wModule Authors%w
-%s
+%a
 
 %wPHP Documentation%w
-%s
+%a
 
 PHP Quality Assurance Team
-%s
+%a
 
 PHP Website Team
-%s
+%a
 bool(true)
 
 Warning: phpcredits() expects parameter 1 to be long, array given in 
%sphpcredits.php on 

[PHP-CVS] cvs: php-src(PHP_5_2) /ext/tidy tidy.c /ext/tidy/tests 029.phpt

2007-09-20 Thread Nuno Lopes
nlopess Thu Sep 20 22:25:06 2007 UTC

  Added files: (Branch: PHP_5_2)
/php-src/ext/tidy/tests 029.phpt 

  Modified files:  
/php-src/ext/tidy   tidy.c 
  Log:
  fix crash when fetching a node type that doesnt exist
  # reported in a manual user note
  
http://cvs.php.net/viewvc.cgi/php-src/ext/tidy/tidy.c?r1=1.66.2.8.2.23r2=1.66.2.8.2.24diff_format=u
Index: php-src/ext/tidy/tidy.c
diff -u php-src/ext/tidy/tidy.c:1.66.2.8.2.23 
php-src/ext/tidy/tidy.c:1.66.2.8.2.24
--- php-src/ext/tidy/tidy.c:1.66.2.8.2.23   Fri May  4 17:11:05 2007
+++ php-src/ext/tidy/tidy.c Thu Sep 20 22:25:05 2007
@@ -16,7 +16,7 @@
   +--+
 */
 
-/* $Id: tidy.c,v 1.66.2.8.2.23 2007/05/04 17:11:05 nlopess Exp $ */
+/* $Id: tidy.c,v 1.66.2.8.2.24 2007/09/20 22:25:05 nlopess Exp $ */
 
 #ifdef HAVE_CONFIG_H
 #include config.h
@@ -870,35 +870,41 @@
return NULL;
 }
 
-static void php_tidy_create_node(INTERNAL_FUNCTION_PARAMETERS, 
tidy_base_nodetypes node)
+static void php_tidy_create_node(INTERNAL_FUNCTION_PARAMETERS, 
tidy_base_nodetypes node_type)
 {
PHPTidyObj *newobj;
+   TidyNode node;
TIDY_FETCH_OBJECT;
 
-   tidy_instanciate(tidy_ce_node, return_value TSRMLS_CC);
-   newobj = (PHPTidyObj *) zend_object_store_get_object(return_value 
TSRMLS_CC);
-   newobj-type = is_node;
-   newobj-ptdoc = obj-ptdoc;
-   newobj-ptdoc-ref_count++;
-
-   switch(node) {
+   switch (node_type) {
case is_root_node:
-   newobj-node = tidyGetRoot(newobj-ptdoc-doc);
+   node = tidyGetRoot(obj-ptdoc-doc);
break;
 
case is_html_node:
-   newobj-node = tidyGetHtml(newobj-ptdoc-doc);
+   node = tidyGetHtml(obj-ptdoc-doc);
break;
 
case is_head_node:
-   newobj-node = tidyGetHead(newobj-ptdoc-doc);
+   node = tidyGetHead(obj-ptdoc-doc);
break;
 
case is_body_node:
-   newobj-node = tidyGetBody(newobj-ptdoc-doc);
+   node = tidyGetBody(obj-ptdoc-doc);
break;
}
 
+   if (!node) {
+   RETURN_NULL();
+   }
+
+   tidy_instanciate(tidy_ce_node, return_value TSRMLS_CC);
+   newobj = (PHPTidyObj *) zend_object_store_get_object(return_value 
TSRMLS_CC);
+   newobj-type  = is_node;
+   newobj-ptdoc = obj-ptdoc;
+   newobj-node  = node;
+   newobj-ptdoc-ref_count++;
+
tidy_add_default_properties(newobj, is_node TSRMLS_CC);
 }
 
@@ -992,7 +998,7 @@
php_info_print_table_start();
php_info_print_table_header(2, Tidy support, enabled);
php_info_print_table_row(2, libTidy Release, (char 
*)tidyReleaseDate());
-   php_info_print_table_row(2, Extension Version, 
PHP_TIDY_MODULE_VERSION  ($Id: tidy.c,v 1.66.2.8.2.23 2007/05/04 17:11:05 
nlopess Exp $));
+   php_info_print_table_row(2, Extension Version, 
PHP_TIDY_MODULE_VERSION  ($Id: tidy.c,v 1.66.2.8.2.24 2007/09/20 22:25:05 
nlopess Exp $));
php_info_print_table_end();
 
DISPLAY_INI_ENTRIES();

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

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



[PHP-CVS] cvs: php-src /ext/tidy tidy.c /ext/tidy/tests 029.phpt

2007-09-20 Thread Nuno Lopes
nlopess Thu Sep 20 22:30:49 2007 UTC

  Modified files:  
/php-src/ext/tidy   tidy.c 
/php-src/ext/tidy/tests 029.phpt 
  Log:
  MFB: fix crash in tidy_get_body() and related functions when the node doesnt 
exist
  
http://cvs.php.net/viewvc.cgi/php-src/ext/tidy/tidy.c?r1=1.113r2=1.114diff_format=u
Index: php-src/ext/tidy/tidy.c
diff -u php-src/ext/tidy/tidy.c:1.113 php-src/ext/tidy/tidy.c:1.114
--- php-src/ext/tidy/tidy.c:1.113   Fri May  4 17:45:56 2007
+++ php-src/ext/tidy/tidy.c Thu Sep 20 22:30:48 2007
@@ -16,7 +16,7 @@
   +--+
 */
 
-/* $Id: tidy.c,v 1.113 2007/05/04 17:45:56 nlopess Exp $ */
+/* $Id: tidy.c,v 1.114 2007/09/20 22:30:48 nlopess Exp $ */
 
 #ifdef HAVE_CONFIG_H
 #include config.h
@@ -902,37 +902,42 @@
return NULL;
 }
 
-static void php_tidy_create_node(INTERNAL_FUNCTION_PARAMETERS, 
tidy_base_nodetypes node)
+static void php_tidy_create_node(INTERNAL_FUNCTION_PARAMETERS, 
tidy_base_nodetypes node_type)
 {
PHPTidyObj *newobj;
+   TidyNode node;
TIDY_FETCH_OBJECT;
 
-   tidy_instanciate(tidy_ce_node, return_value TSRMLS_CC);
-   newobj = (PHPTidyObj *) zend_object_store_get_object(return_value 
TSRMLS_CC);
-   newobj-type = is_node;
-   newobj-ptdoc = obj-ptdoc;
-   newobj-ptdoc-ref_count++;
-   newobj-converter = obj-converter;
-   if (obj-converter) obj-converter-ref_count++;
-
-   switch(node) {
+   switch (node_type) {
case is_root_node:
-   newobj-node = tidyGetRoot(newobj-ptdoc-doc);
+   node = tidyGetRoot(obj-ptdoc-doc);
break;
 
case is_html_node:
-   newobj-node = tidyGetHtml(newobj-ptdoc-doc);
+   node = tidyGetHtml(obj-ptdoc-doc);
break;
 
case is_head_node:
-   newobj-node = tidyGetHead(newobj-ptdoc-doc);
+   node = tidyGetHead(obj-ptdoc-doc);
break;
 
case is_body_node:
-   newobj-node = tidyGetBody(newobj-ptdoc-doc);
+   node = tidyGetBody(obj-ptdoc-doc);
break;
}
 
+   if (!node) {
+   RETURN_NULL();
+   }
+
+   tidy_instanciate(tidy_ce_node, return_value TSRMLS_CC);
+   newobj = (PHPTidyObj *) zend_object_store_get_object(return_value 
TSRMLS_CC);
+   newobj-type = is_node;
+   newobj-ptdoc = obj-ptdoc;
+   newobj-ptdoc-ref_count++;
+   newobj-converter = obj-converter;
+   if (obj-converter) obj-converter-ref_count++;
+
tidy_add_default_properties(newobj, is_node TSRMLS_CC);
 }
 
@@ -1056,7 +1061,7 @@
php_info_print_table_start();
php_info_print_table_header(2, Tidy support, enabled);
php_info_print_table_row(2, libTidy Release, (char 
*)tidyReleaseDate());
-   php_info_print_table_row(2, Extension Version, 
PHP_TIDY_MODULE_VERSION  ($Id: tidy.c,v 1.113 2007/05/04 17:45:56 nlopess Exp 
$));
+   php_info_print_table_row(2, Extension Version, 
PHP_TIDY_MODULE_VERSION  ($Id: tidy.c,v 1.114 2007/09/20 22:30:48 nlopess Exp 
$));
php_info_print_table_end();
 
DISPLAY_INI_ENTRIES();
http://cvs.php.net/viewvc.cgi/php-src/ext/tidy/tests/029.phpt?r1=1.1r2=1.2diff_format=u
Index: php-src/ext/tidy/tests/029.phpt
diff -u /dev/null php-src/ext/tidy/tests/029.phpt:1.2
--- /dev/null   Thu Sep 20 22:30:49 2007
+++ php-src/ext/tidy/tests/029.phpt Thu Sep 20 22:30:49 2007
@@ -0,0 +1,28 @@
+--TEST--
+tidy_get_body() crash
+--SKIPIF--
+?php if (!extension_loaded('tidy')) die('skip'); ?
+--FILE--
+?php
+
+// bug report taken from http://news.php.net/php.notes/130628
+
+$inputs = array(
+   'frameset  /frameset',
+   'htmlframeset /frameset /html',
+);
+
+
+foreach ($inputs as $input) { 
+
+   $t = tidy_parse_string($input);
+   $t-cleanRepair();
+   var_dump(tidy_get_body($t));
+}
+
+echo Done\n;
+?
+--EXPECT--
+NULL
+NULL
+Done

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



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

2007-09-20 Thread Nuno Lopes
nlopess Thu Sep 20 22:44:18 2007 UTC

  Modified files:  
/php-src/ext/tidy   tidy.c 
  Log:
  oops.. thats what you get for commiting code without compiling nor testing..
  
http://cvs.php.net/viewvc.cgi/php-src/ext/tidy/tidy.c?r1=1.114r2=1.115diff_format=u
Index: php-src/ext/tidy/tidy.c
diff -u php-src/ext/tidy/tidy.c:1.114 php-src/ext/tidy/tidy.c:1.115
--- php-src/ext/tidy/tidy.c:1.114   Thu Sep 20 22:30:48 2007
+++ php-src/ext/tidy/tidy.c Thu Sep 20 22:44:17 2007
@@ -16,7 +16,7 @@
   +--+
 */
 
-/* $Id: tidy.c,v 1.114 2007/09/20 22:30:48 nlopess Exp $ */
+/* $Id: tidy.c,v 1.115 2007/09/20 22:44:17 nlopess Exp $ */
 
 #ifdef HAVE_CONFIG_H
 #include config.h
@@ -932,8 +932,9 @@
 
tidy_instanciate(tidy_ce_node, return_value TSRMLS_CC);
newobj = (PHPTidyObj *) zend_object_store_get_object(return_value 
TSRMLS_CC);
-   newobj-type = is_node;
+   newobj-type  = is_node;
newobj-ptdoc = obj-ptdoc;
+   newobj-node  = node;
newobj-ptdoc-ref_count++;
newobj-converter = obj-converter;
if (obj-converter) obj-converter-ref_count++;
@@ -1061,7 +1062,7 @@
php_info_print_table_start();
php_info_print_table_header(2, Tidy support, enabled);
php_info_print_table_row(2, libTidy Release, (char 
*)tidyReleaseDate());
-   php_info_print_table_row(2, Extension Version, 
PHP_TIDY_MODULE_VERSION  ($Id: tidy.c,v 1.114 2007/09/20 22:30:48 nlopess Exp 
$));
+   php_info_print_table_row(2, Extension Version, 
PHP_TIDY_MODULE_VERSION  ($Id: tidy.c,v 1.115 2007/09/20 22:44:17 nlopess Exp 
$));
php_info_print_table_end();
 
DISPLAY_INI_ENTRIES();

-- 
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) / NEWS /ext/bcmath bcmath.c /ext/bz2 bz2.c /ext/calendar calendar.c /ext/com_dotnet com_extension.c com_persist.c /ext/ctype ctype.c /ext/curl interface.c /e

2007-09-27 Thread Nuno Lopes

Many many many many many many thanks!
When I opened this e-mail I though I was dreaming, but no, it finally 
happened :)


Thank you both,
Nuno



dmitry Thu Sep 27 18:00:49 2007 UTC

 Modified files:  (Branch: PHP_5_3)
   /php-src NEWS
   /ZendEngine2 zend.h zend_API.c zend_API.h zend_builtin_functions.c
   zend_compile.c zend_compile.h zend_exceptions.c
   zend_execute.c zend_execute.h zend_execute_API.c
   zend_hash.c zend_hash.h zend_ini.c zend_ini.h
   zend_interfaces.c zend_modules.h zend_opcode.c
   /php-src/ext/bcmath bcmath.c
   /php-src/ext/bz2 bz2.c
   /php-src/ext/calendar calendar.c
   /php-src/ext/com_dotnet com_extension.c com_persist.c
   /php-src/ext/ctype ctype.c
   /php-src/ext/curl interface.c
   /php-src/ext/date php_date.c
   /php-src/ext/dba dba.c
   /php-src/ext/dbase dbase.c
   /php-src/ext/dom attr.c cdatasection.c characterdata.c comment.c
   document.c documentfragment.c documenttype.c
   dom_fe.h domconfiguration.c domerror.c
   domerrorhandler.c domexception.c
   domimplementation.c domimplementationlist.c
   domimplementationsource.c domlocator.c
   domstringlist.c element.c entity.c
   entityreference.c namednodemap.c namelist.c node.c
   nodelist.c notation.c php_dom.c
   processinginstruction.c string_extend.c text.c
   typeinfo.c userdatahandler.c xpath.c
   /php-src/ext/exif exif.c
   /php-src/ext/fbsql php_fbsql.c
   /php-src/ext/fdf fdf.c
   /php-src/ext/filter filter.c
   /php-src/ext/ftp php_ftp.c
   /php-src/ext/gd gd.c
   /php-src/ext/gettext gettext.c
   /php-src/ext/gmp gmp.c
   /php-src/ext/hash hash.c
   /php-src/ext/iconv iconv.c
   /php-src/ext/imap php_imap.c
   /php-src/ext/interbase interbase.c
   /php-src/ext/json json.c
   /php-src/ext/ldap ldap.c
   /php-src/ext/libxml libxml.c
   /php-src/ext/mbstring mbstring.c
   /php-src/ext/mcrypt mcrypt.c
   /php-src/ext/mhash mhash.c
   /php-src/ext/mime_magic mime_magic.c
   /php-src/ext/ming ming.c
   /php-src/ext/msql php_msql.c
   /php-src/ext/mssql php_mssql.c
   /php-src/ext/mysql php_mysql.c
   /php-src/ext/mysqli mysqli.c mysqli_driver.c mysqli_exception.c
  mysqli_fe.c mysqli_warning.c php_mysqli.h
   /php-src/ext/ncurses ncurses_fe.c php_ncurses.h
   /php-src/ext/oci8 oci8.c
   /php-src/ext/odbc birdstep.c php_odbc.c
   /php-src/ext/openssl openssl.c
   /php-src/ext/pcntl pcntl.c
   /php-src/ext/pcre php_pcre.c
   /php-src/ext/pdo pdo.c pdo_dbh.c pdo_stmt.c php_pdo_driver.h
   php_pdo_int.h
   /php-src/ext/pdo_dblib pdo_dblib.c
   /php-src/ext/pdo_firebird pdo_firebird.c
   /php-src/ext/pdo_mysql pdo_mysql.c
   /php-src/ext/pdo_oci pdo_oci.c
   /php-src/ext/pdo_odbc pdo_odbc.c
   /php-src/ext/pdo_pgsql pdo_pgsql.c pgsql_driver.c
   /php-src/ext/pdo_sqlite pdo_sqlite.c sqlite_driver.c
   /php-src/ext/pgsql pgsql.c
   /php-src/ext/posix posix.c
   /php-src/ext/pspell pspell.c
   /php-src/ext/readline readline.c
   /php-src/ext/recode recode.c
   /php-src/ext/reflection php_reflection.c
   /php-src/ext/session session.c
   /php-src/ext/shmop shmop.c
   /php-src/ext/simplexml simplexml.c
   /php-src/ext/skeleton skeleton.c
   /php-src/ext/snmp snmp.c winsnmp.c
   /php-src/ext/soap soap.c
   /php-src/ext/sockets sockets.c
   /php-src/ext/spl php_spl.c spl_array.c spl_directory.c
   spl_functions.c spl_functions.h spl_iterators.c
   spl_observer.c spl_sxe.c
   /php-src/ext/sqlite pdo_sqlite2.c sqlite.c
   /php-src/ext/standard basic_functions.c dir.c dl.c info.c
user_filters.c
   /php-src/ext/sybase php_sybase_db.c
   /php-src/ext/sybase_ct php_sybase_ct.c
   /php-src/ext/sysvmsg sysvmsg.c
   /php-src/ext/sysvsem sysvsem.c
   /php-src/ext/sysvshm sysvshm.c
   /php-src/ext/tidy tidy.c
   /php-src/ext/tokenizer tokenizer.c
   /php-src/ext/wddx wddx.c
   /php-src/ext/xml xml.c
   /php-src/ext/xmlreader php_xmlreader.c
   /php-src/ext/xmlrpc xmlrpc-epi-php.c
   /php-src/ext/xmlwriter php_xmlwriter.c
   /php-src/ext/xsl php_xsl.c xsl_fe.h xsltprocessor.c
   /php-src/ext/zip php_zip.c
   /php-src/ext/zlib zlib.c
   /php-src/sapi/aolserver aolserver.c
   /php-src/sapi/apache php_apache.c
   /php-src/sapi/apache2filter php_functions.c
   /php-src/sapi/apache2handler php_functions.c
   /php-src/sapi/apache_hooks php_apache.c
   /php-src/sapi/continuity capi.c
   /php-src/sapi/milter php_milter.c
   /php-src/sapi/nsapi nsapi.c
 Log:
 Improved memory usage by movig constants to read only memory. (Dmitry, 
Pierre) 


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



[PHP-CVS] Re: [PHP-DEV] Re: cvs: php-src(PHP_5_2) / run-tests.php /ext/bz2/tests 005.phpt /ext/standard/tests/general_functions phpcredits.phpt phpinfo.phpt /ext/standard/tests/strings sha1.phpt /

2007-09-28 Thread Nuno Lopes

nlopess Fri Sep 14 15:28:04 2007 UTC
  Log:
  changes to run-tests.php:
  - change %s to %a
  - make %s = [^\r\n]+
  - fix tests accordingly



I think this is a very bad change.  While tests of bundled extensions
can be updated accordingly, pecl extension tests have no way to be
version agnostic in this regard.

Mike - that's a fair point. When we looked through the PHP tests we found 
that the vast majority (all except 4) relied on the %s behaviour as is is 
currently implemented - that is *not* matching over a line end. Only 4 
tests were actually intentionally using %s to match over line endings. 
From what you say it sounds as though many more of the PECL tests behave 
this way?


Exactly. Although this may (and does) break some tests, the vast majority of 
the tests should continue working correctly.
I think that the change is important enough to award this BC break. In PECL 
extensions, if you really need the old behavior, you can always use 
the --EXPECTREGEX-- section.


Nuno 


--
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/general_functions phpinfo.phpt

2007-09-28 Thread Nuno Lopes
nlopess Fri Sep 28 22:40:23 2007 UTC

  Modified files:  
/php-src/ext/standard/tests/general_functions   phpinfo.phpt 
  Log:
  fix expected output
  
http://cvs.php.net/viewvc.cgi/php-src/ext/standard/tests/general_functions/phpinfo.phpt?r1=1.3r2=1.4diff_format=u
Index: php-src/ext/standard/tests/general_functions/phpinfo.phpt
diff -u php-src/ext/standard/tests/general_functions/phpinfo.phpt:1.3 
php-src/ext/standard/tests/general_functions/phpinfo.phpt:1.4
--- php-src/ext/standard/tests/general_functions/phpinfo.phpt:1.3   Fri Sep 
14 15:36:29 2007
+++ php-src/ext/standard/tests/general_functions/phpinfo.phpt   Fri Sep 28 
22:40:23 2007
@@ -31,7 +31,9 @@
 Debug Build = %s
 Thread Safety = %s
 Zend Memory Manager = %s
+Unicode Support = %s
 IPv6 Support = %s
+
 Registered PHP Streams = %s
 Registered Stream Socket Transports = %s
 Registered Stream Filters = %s

-- 
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/openssl xp_ssl.c /ext/standard var_unserializer.c var_unserializer.re /main php_variables.c /sapi/cli php_cli_readline.c

2007-09-29 Thread Nuno Lopes
nlopess Sat Sep 29 11:18:42 2007 UTC

  Modified files:  (Branch: PHP_5_3)
/php-src/ext/opensslxp_ssl.c 
/php-src/ext/standard   var_unserializer.c var_unserializer.re 
/php-src/main   php_variables.c 
/php-src/sapi/cli   php_cli_readline.c 
  Log:
  fix a few compiler warnings (mostly use of unitialized values)
  
http://cvs.php.net/viewvc.cgi/php-src/ext/openssl/xp_ssl.c?r1=1.22.2.3.2.9r2=1.22.2.3.2.9.2.1diff_format=u
Index: php-src/ext/openssl/xp_ssl.c
diff -u php-src/ext/openssl/xp_ssl.c:1.22.2.3.2.9 
php-src/ext/openssl/xp_ssl.c:1.22.2.3.2.9.2.1
--- php-src/ext/openssl/xp_ssl.c:1.22.2.3.2.9   Mon Jul  2 16:42:10 2007
+++ php-src/ext/openssl/xp_ssl.cSat Sep 29 11:18:41 2007
@@ -16,7 +16,7 @@
   +--+
 */
 
-/* $Id: xp_ssl.c,v 1.22.2.3.2.9 2007/07/02 16:42:10 iliaa Exp $ */
+/* $Id: xp_ssl.c,v 1.22.2.3.2.9.2.1 2007/09/29 11:18:41 nlopess Exp $ */
 
 #include php.h
 #include ext/standard/file.h
@@ -490,8 +490,8 @@

zend_list_insert(mycert,

php_openssl_get_x509_list_id()));

add_next_index_zval(arr, zcert);
-   }
efree(zcert);
+   }
 
} else {
ZVAL_NULL(arr);
http://cvs.php.net/viewvc.cgi/php-src/ext/standard/var_unserializer.c?r1=1.70.2.4.2.7r2=1.70.2.4.2.7.2.1diff_format=u
Index: php-src/ext/standard/var_unserializer.c
diff -u php-src/ext/standard/var_unserializer.c:1.70.2.4.2.7 
php-src/ext/standard/var_unserializer.c:1.70.2.4.2.7.2.1
--- php-src/ext/standard/var_unserializer.c:1.70.2.4.2.7Mon Aug  6 
18:33:29 2007
+++ php-src/ext/standard/var_unserializer.c Sat Sep 29 11:18:41 2007
@@ -1,4 +1,4 @@
-/* Generated by re2c 0.12.1 on Mon Aug  6 21:32:14 2007 */
+/* Generated by re2c 0.12.0 on Sat Sep 29 11:44:15 2007 */
 #line 1 ext/standard/var_unserializer.re
 /*
   +--+
@@ -18,7 +18,7 @@
   +--+
 */
 
-/* $Id: var_unserializer.c,v 1.70.2.4.2.7 2007/08/06 18:33:29 jani Exp $ */
+/* $Id: var_unserializer.c,v 1.70.2.4.2.7.2.1 2007/09/29 11:18:41 nlopess Exp 
$ */
 
 #include php.h
 #include ext/standard/php_var.h
@@ -334,7 +334,7 @@
(*p) += 2;
 
if (datalen  0 || (*p) + datalen = max) {
-   zend_error(E_WARNING, Insufficient data for unserializing - 
%ld required, %ld present, datalen, max - (*p));
+   zend_error(E_WARNING, Insufficient data for unserializing - 
%ld required, %ld present, datalen, (long)(max - (*p)));
return 0;
}
 
http://cvs.php.net/viewvc.cgi/php-src/ext/standard/var_unserializer.re?r1=1.52.2.2.2.6r2=1.52.2.2.2.6.2.1diff_format=u
Index: php-src/ext/standard/var_unserializer.re
diff -u php-src/ext/standard/var_unserializer.re:1.52.2.2.2.6 
php-src/ext/standard/var_unserializer.re:1.52.2.2.2.6.2.1
--- php-src/ext/standard/var_unserializer.re:1.52.2.2.2.6   Mon Aug  6 
18:23:16 2007
+++ php-src/ext/standard/var_unserializer.reSat Sep 29 11:18:41 2007
@@ -16,7 +16,7 @@
   +--+
 */
 
-/* $Id: var_unserializer.re,v 1.52.2.2.2.6 2007/08/06 18:23:16 jani Exp $ */
+/* $Id: var_unserializer.re,v 1.52.2.2.2.6.2.1 2007/09/29 11:18:41 nlopess Exp 
$ */
 
 #include php.h
 #include ext/standard/php_var.h
@@ -338,7 +338,7 @@
(*p) += 2;
 
if (datalen  0 || (*p) + datalen = max) {
-   zend_error(E_WARNING, Insufficient data for unserializing - 
%ld required, %ld present, datalen, max - (*p));
+   zend_error(E_WARNING, Insufficient data for unserializing - 
%ld required, %ld present, datalen, (long)(max - (*p)));
return 0;
}
 
http://cvs.php.net/viewvc.cgi/php-src/main/php_variables.c?r1=1.104.2.10.2.11r2=1.104.2.10.2.11.2.1diff_format=u
Index: php-src/main/php_variables.c
diff -u php-src/main/php_variables.c:1.104.2.10.2.11 
php-src/main/php_variables.c:1.104.2.10.2.11.2.1
--- php-src/main/php_variables.c:1.104.2.10.2.11Wed Jul 18 11:46:50 2007
+++ php-src/main/php_variables.cSat Sep 29 11:18:41 2007
@@ -17,7 +17,7 @@
+--+
  */
 
-/* $Id: php_variables.c,v 1.104.2.10.2.11 2007/07/18 11:46:50 tony2001 Exp $ */
+/* $Id: php_variables.c,v 1.104.2.10.2.11.2.1 2007/09/29 11:18:41 nlopess Exp 
$ */
 
 #include stdio.h
 #include php.h
@@ -130,11 +130,12 @@
 
  

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

2007-09-29 Thread Nuno Lopes
nlopess Sat Sep 29 11:24:06 2007 UTC

  Modified files:  (Branch: PHP_5_3)
/php-src/ext/opensslxp_ssl.c 
  Log:
  use FREE_ZVAL() instead of free() to free a zval
  
http://cvs.php.net/viewvc.cgi/php-src/ext/openssl/xp_ssl.c?r1=1.22.2.3.2.9.2.1r2=1.22.2.3.2.9.2.2diff_format=u
Index: php-src/ext/openssl/xp_ssl.c
diff -u php-src/ext/openssl/xp_ssl.c:1.22.2.3.2.9.2.1 
php-src/ext/openssl/xp_ssl.c:1.22.2.3.2.9.2.2
--- php-src/ext/openssl/xp_ssl.c:1.22.2.3.2.9.2.1   Sat Sep 29 11:18:41 2007
+++ php-src/ext/openssl/xp_ssl.cSat Sep 29 11:24:05 2007
@@ -16,7 +16,7 @@
   +--+
 */
 
-/* $Id: xp_ssl.c,v 1.22.2.3.2.9.2.1 2007/09/29 11:18:41 nlopess Exp $ */
+/* $Id: xp_ssl.c,v 1.22.2.3.2.9.2.2 2007/09/29 11:24:05 nlopess Exp $ */
 
 #include php.h
 #include ext/standard/file.h
@@ -464,7 +464,7 @@
ssl, 
peer_certificate,
zcert);
peer_cert = NULL;
-   efree(zcert);
+   FREE_ZVAL(zcert);
}
 
if (SUCCESS == 
php_stream_context_get_option(
@@ -490,7 +490,7 @@

zend_list_insert(mycert,

php_openssl_get_x509_list_id()));

add_next_index_zval(arr, zcert);
-   efree(zcert);
+   
FREE_ZVAL(zcert);
}
 
} else {

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



[PHP-CVS] cvs: php-src /ext/openssl xp_ssl.c /ext/standard var_unserializer.c var_unserializer.re /sapi/cli php_cli_readline.c

2007-09-29 Thread Nuno Lopes
nlopess Sat Sep 29 11:26:51 2007 UTC

  Modified files:  
/php-src/ext/opensslxp_ssl.c 
/php-src/ext/standard   var_unserializer.c var_unserializer.re 
/php-src/sapi/cli   php_cli_readline.c 
  Log:
  MFB: fix compiler warnings
  
http://cvs.php.net/viewvc.cgi/php-src/ext/openssl/xp_ssl.c?r1=1.33r2=1.34diff_format=u
Index: php-src/ext/openssl/xp_ssl.c
diff -u php-src/ext/openssl/xp_ssl.c:1.33 php-src/ext/openssl/xp_ssl.c:1.34
--- php-src/ext/openssl/xp_ssl.c:1.33   Sun May 27 19:13:11 2007
+++ php-src/ext/openssl/xp_ssl.cSat Sep 29 11:26:51 2007
@@ -16,7 +16,7 @@
   +--+
 */
 
-/* $Id: xp_ssl.c,v 1.33 2007/05/27 19:13:11 tony2001 Exp $ */
+/* $Id: xp_ssl.c,v 1.34 2007/09/29 11:26:51 nlopess Exp $ */
 
 #include php.h
 #include ext/standard/file.h
@@ -464,7 +464,7 @@
ssl, 
peer_certificate,
zcert);
peer_cert = NULL;
-   efree(zcert);
+   FREE_ZVAL(zcert);
}
 
if (SUCCESS == 
php_stream_context_get_option(
@@ -490,8 +490,8 @@

zend_list_insert(mycert,

php_openssl_get_x509_list_id()));

add_next_index_zval(arr, zcert);
+   
FREE_ZVAL(zcert);
}
-   efree(zcert);
} else {
ZVAL_NULL(arr);
}
http://cvs.php.net/viewvc.cgi/php-src/ext/standard/var_unserializer.c?r1=1.90r2=1.91diff_format=u
Index: php-src/ext/standard/var_unserializer.c
diff -u php-src/ext/standard/var_unserializer.c:1.90 
php-src/ext/standard/var_unserializer.c:1.91
--- php-src/ext/standard/var_unserializer.c:1.90Mon Aug  6 18:30:53 2007
+++ php-src/ext/standard/var_unserializer.c Sat Sep 29 11:26:51 2007
@@ -18,7 +18,7 @@
   +--+
 */
 
-/* $Id: var_unserializer.c,v 1.90 2007/08/06 18:30:53 jani Exp $ */
+/* $Id: var_unserializer.c,v 1.91 2007/09/29 11:26:51 nlopess Exp $ */
 
 #include php.h
 #include ext/standard/php_var.h
@@ -388,7 +388,7 @@
}
 
if (datalen  0 || (*p) + datalen = max) {
-   zend_error(E_WARNING, Insufficient data for unserializing - 
%ld required, %ld present, datalen, max - (*p));
+   zend_error(E_WARNING, Insufficient data for unserializing - 
%ld required, %ld present, datalen, (long)(max - (*p)));
return 0;
}
 
http://cvs.php.net/viewvc.cgi/php-src/ext/standard/var_unserializer.re?r1=1.69r2=1.70diff_format=u
Index: php-src/ext/standard/var_unserializer.re
diff -u php-src/ext/standard/var_unserializer.re:1.69 
php-src/ext/standard/var_unserializer.re:1.70
--- php-src/ext/standard/var_unserializer.re:1.69   Mon Aug  6 18:25:41 2007
+++ php-src/ext/standard/var_unserializer.reSat Sep 29 11:26:51 2007
@@ -16,7 +16,7 @@
   +--+
 */
 
-/* $Id: var_unserializer.re,v 1.69 2007/08/06 18:25:41 jani Exp $ */
+/* $Id: var_unserializer.re,v 1.70 2007/09/29 11:26:51 nlopess Exp $ */
 
 #include php.h
 #include ext/standard/php_var.h
@@ -392,7 +392,7 @@
}
 
if (datalen  0 || (*p) + datalen = max) {
-   zend_error(E_WARNING, Insufficient data for unserializing - 
%ld required, %ld present, datalen, max - (*p));
+   zend_error(E_WARNING, Insufficient data for unserializing - 
%ld required, %ld present, datalen, (long)(max - (*p)));
return 0;
}
 
http://cvs.php.net/viewvc.cgi/php-src/sapi/cli/php_cli_readline.c?r1=1.12r2=1.13diff_format=u
Index: php-src/sapi/cli/php_cli_readline.c
diff -u php-src/sapi/cli/php_cli_readline.c:1.12 
php-src/sapi/cli/php_cli_readline.c:1.13
--- php-src/sapi/cli/php_cli_readline.c:1.12Mon Jan  1 09:29:36 2007
+++ php-src/sapi/cli/php_cli_readline.c Sat Sep 29 11:26:51 2007
@@ -17,7 +17,7 @@
+--+
 */
 
-/* $Id: php_cli_readline.c,v 1.12 2007/01/01 09:29:36 sebastian Exp $ */
+/* $Id: php_cli_readline.c,v 1.13 2007/09/29 11:26:51 nlopess Exp $ */
 
 #include php.h
 
@@ -423,7 +423,7 @@
 
 - future: respect scope (php  function foo() { $[tab] should only expand to 

Re: [PHP-CVS] cvs: php-src(PHP_5_3) / NEWS configure.in /ext/standard basic_functions.c basic_functions.h config.m4 /ext/standard/tests/array extract_error.phpt /ext/standard/tests/general_function

2007-10-02 Thread Nuno Lopes

 MFH:- Added common getopt implementation to core.
 MFH:- Added long-option feature to getopt().
 MFH:- Made getopt() available on win32 systems.
 MFH:  Patch by: David Soria Parra [EMAIL PROTECTED]
 [DOC]: These changes will be available from 5.3+



uhm, this doesn't sound much thread safe to me:



PHPAPI int php_optidx = -1;

PHPAPI int php_getopt(int argc, char* const *argv, const opt_struct 
opts[], char **optarg, int *optind, int show_err, int arg_start) /* {{{ */

{
 static int optchr = 0;
 static int dash = 0; /* have already seen the - */

 php_optidx = -1;

(...)


Nuno 


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



[PHP-CVS] cvs: php-src / configure.in

2007-10-05 Thread Nuno Lopes
nlopess Fri Oct  5 14:49:40 2007 UTC

  Modified files:  
/php-srcconfigure.in 
  Log:
  MFB: allow lcov 1.6
  
http://cvs.php.net/viewvc.cgi/php-src/configure.in?r1=1.641r2=1.642diff_format=u
Index: php-src/configure.in
diff -u php-src/configure.in:1.641 php-src/configure.in:1.642
--- php-src/configure.in:1.641  Mon Oct  1 12:32:39 2007
+++ php-src/configure.inFri Oct  5 14:49:40 2007
@@ -1,4 +1,4 @@
-## $Id: configure.in,v 1.641 2007/10/01 12:32:39 jani Exp $ -*- autoconf -*-
+## $Id: configure.in,v 1.642 2007/10/05 14:49:40 nlopess Exp $ -*- autoconf -*-
 dnl ## Process this file with autoconf to produce a configure script.
 
 divert(1)
@@ -643,7 +643,7 @@
 AC_MSG_ERROR([ccache must be disabled when --enable-gcov option is used. 
You can disable ccache by setting environment variable CCACHE_DISABLE=1.])
   fi
   
-  ltp_version_list=1.5
+  ltp_version_list=1.5 1.6
 
   AC_CHECK_PROG(LTP, lcov, lcov)
   AC_CHECK_PROG(LTP_GENHTML, genhtml, genhtml)

-- 
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) / configure.in

2007-10-05 Thread Nuno Lopes
nlopess Fri Oct  5 14:48:32 2007 UTC

  Modified files:  (Branch: PHP_5_3)
/php-srcconfigure.in 
  Log:
  lcov 1.6 also works correctly
  
http://cvs.php.net/viewvc.cgi/php-src/configure.in?r1=1.579.2.52.2.77.2.3r2=1.579.2.52.2.77.2.4diff_format=u
Index: php-src/configure.in
diff -u php-src/configure.in:1.579.2.52.2.77.2.3 
php-src/configure.in:1.579.2.52.2.77.2.4
--- php-src/configure.in:1.579.2.52.2.77.2.3Fri Oct  5 12:34:48 2007
+++ php-src/configure.inFri Oct  5 14:48:32 2007
@@ -1,4 +1,4 @@
-## $Id: configure.in,v 1.579.2.52.2.77.2.3 2007/10/05 12:34:48 jani Exp $ -*- 
autoconf -*-
+## $Id: configure.in,v 1.579.2.52.2.77.2.4 2007/10/05 14:48:32 nlopess Exp $ 
-*- autoconf -*-
 dnl ## Process this file with autoconf to produce a configure script.
 
 divert(1)
@@ -646,7 +646,7 @@
 AC_MSG_ERROR([ccache must be disabled when --enable-gcov option is used. 
You can disable ccache by setting environment variable CCACHE_DISABLE=1.])
   fi
   
-  ltp_version_list=1.5
+  ltp_version_list=1.5 1.6
 
   AC_CHECK_PROG(LTP, lcov, lcov)
   AC_CHECK_PROG(LTP_GENHTML, genhtml, genhtml)

-- 
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) / configure.in

2007-10-05 Thread Nuno Lopes
nlopess Fri Oct  5 14:51:36 2007 UTC

  Modified files:  (Branch: PHP_5_2)
/php-srcconfigure.in 
  Log:
  allow lcov 1.6
  
http://cvs.php.net/viewvc.cgi/php-src/configure.in?r1=1.579.2.52.2.77r2=1.579.2.52.2.78diff_format=u
Index: php-src/configure.in
diff -u php-src/configure.in:1.579.2.52.2.77 
php-src/configure.in:1.579.2.52.2.78
--- php-src/configure.in:1.579.2.52.2.77Thu Aug 30 07:40:13 2007
+++ php-src/configure.inFri Oct  5 14:51:36 2007
@@ -1,4 +1,4 @@
-## $Id: configure.in,v 1.579.2.52.2.77 2007/08/30 07:40:13 sebastian Exp $ -*- 
autoconf -*-
+## $Id: configure.in,v 1.579.2.52.2.78 2007/10/05 14:51:36 nlopess Exp $ -*- 
autoconf -*-
 dnl ## Process this file with autoconf to produce a configure script.
 
 divert(1)
@@ -646,7 +646,7 @@
 AC_MSG_ERROR([ccache must be disabled when --enable-gcov option is used. 
You can disable ccache by setting environment variable CCACHE_DISABLE=1.])
   fi
   
-  ltp_version_list=1.5
+  ltp_version_list=1.5 1.6
 
   AC_CHECK_PROG(LTP, lcov, lcov)
   AC_CHECK_PROG(LTP_GENHTML, genhtml, genhtml)

-- 
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/pcre php_pcre.c /ext/pcre/tests bug37911.phpt

2007-10-07 Thread Nuno Lopes
nlopess Sun Oct  7 11:48:28 2007 UTC

  Added files: (Branch: PHP_5_3)
/php-src/ext/pcre/tests bug37911.phpt 

  Modified files:  
/php-src/ext/pcre   php_pcre.c 
  Log:
  fix bug #37911:  preg_replace_callback ignores named groups
  
http://cvs.php.net/viewvc.cgi/php-src/ext/pcre/php_pcre.c?r1=1.168.2.9.2.21.2.2r2=1.168.2.9.2.21.2.3diff_format=u
Index: php-src/ext/pcre/php_pcre.c
diff -u php-src/ext/pcre/php_pcre.c:1.168.2.9.2.21.2.2 
php-src/ext/pcre/php_pcre.c:1.168.2.9.2.21.2.3
--- php-src/ext/pcre/php_pcre.c:1.168.2.9.2.21.2.2  Sun Oct  7 05:22:05 2007
+++ php-src/ext/pcre/php_pcre.c Sun Oct  7 11:48:27 2007
@@ -16,7 +16,7 @@
+--+
  */
 
-/* $Id: php_pcre.c,v 1.168.2.9.2.21.2.2 2007/10/07 05:22:05 davidw Exp $ */
+/* $Id: php_pcre.c,v 1.168.2.9.2.21.2.3 2007/10/07 11:48:27 nlopess Exp $ */
 
 #include php.h
 #include php_ini.h
@@ -174,6 +174,49 @@
 }
 /* }}} */
 
+/* {{{ static make_subpats_table */
+static char **make_subpats_table(int num_subpats, int rc, pcre_cache_entry 
*pce)
+{
+   pcre_extra *extra = pce-extra;
+   int name_cnt = 0, name_size, ni = 0;
+   char *name_table;
+   unsigned short name_idx;
+   char **subpat_names = (char **)ecalloc(num_subpats, sizeof(char *));
+
+   rc = pcre_fullinfo(pce-re, extra, PCRE_INFO_NAMECOUNT, name_cnt);
+   if (rc  0) {
+   php_error_docref(NULL TSRMLS_CC, E_WARNING, Internal 
pcre_fullinfo() error %d, rc);
+   efree(subpat_names);
+   return NULL;
+   }
+   if (name_cnt  0) {
+   int rc1, rc2;
+
+   rc1 = pcre_fullinfo(pce-re, extra, PCRE_INFO_NAMETABLE, 
name_table);
+   rc2 = pcre_fullinfo(pce-re, extra, PCRE_INFO_NAMEENTRYSIZE, 
name_size);
+   rc = rc2 ? rc2 : rc1;
+   if (rc  0) {
+   php_error_docref(NULL TSRMLS_CC, E_WARNING, Internal 
pcre_fullinfo() error %d, rc);
+   efree(subpat_names);
+   return NULL;
+   }
+
+   while (ni++  name_cnt) {
+   name_idx = 0xff * name_table[0] + name_table[1];
+   subpat_names[name_idx] = name_table + 2;
+   if (is_numeric_string(subpat_names[name_idx], 
strlen(subpat_names[name_idx]), NULL, NULL, 0)  0) {
+   php_error_docref(NULL TSRMLS_CC, E_WARNING, 
Numeric named subpatterns are not allowed);
+   efree(subpat_names);
+   return NULL;
+   }
+   name_table += name_size;
+   }
+   }
+
+   return subpat_names;
+}
+/* }}} */
+
 /* {{{ pcre_get_compiled_regex_cache
  */
 PHPAPI pcre_cache_entry* pcre_get_compiled_regex_cache(char *regex, int 
regex_len TSRMLS_DC)
@@ -484,7 +527,7 @@
int  g_notempty = 0;/* If the match 
should not be empty */
const char **stringlist;/* Holds list of 
subpatterns */
char*match; /* The current 
match */
-   char   **subpat_names = NULL;/* Array for named subpatterns 
*/
+   char   **subpat_names;  /* Array for named 
subpatterns */
int  i, rc;
int  subpats_order; /* Order of 
subpattern matches */
int  offset_capture;/* Capture match 
offsets: yes/no */
@@ -539,54 +582,19 @@
}
num_subpats++;
size_offsets = num_subpats * 3;
-   offsets = (int *)safe_emalloc(size_offsets, sizeof(int), 0);
 
/*
 * Build a mapping from subpattern numbers to their names. We will 
always
 * allocate the table, even though there may be no named subpatterns. 
This
 * avoids somewhat more complicated logic in the inner loops.
 */
-   subpat_names = (char **)safe_emalloc(num_subpats, sizeof(char *), 0);
-   memset(subpat_names, 0, sizeof(char *) * num_subpats);
-   {
-   int name_cnt = 0, name_size, ni = 0;
-   char *name_table;
-   unsigned short name_idx;
-
-   rc = pcre_fullinfo(pce-re, extra, PCRE_INFO_NAMECOUNT, 
name_cnt);
-   if (rc  0) {
-   php_error_docref(NULL TSRMLS_CC, E_WARNING, Internal 
pcre_fullinfo() error %d, rc);
-   efree(offsets);
-   efree(subpat_names);
-   RETURN_FALSE;
-   }
-   if (name_cnt  0) {
-   int rc1, rc2;
-
-   rc1 = pcre_fullinfo(pce-re, extra, 
PCRE_INFO_NAMETABLE, name_table);
-   rc2 = pcre_fullinfo(pce-re, extra, 
PCRE_INFO_NAMEENTRYSIZE, 

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

2007-10-07 Thread Nuno Lopes
nlopess Sun Oct  7 11:51:36 2007 UTC

  Modified files:  (Branch: PHP_5_3)
/php-srcNEWS 
  Log:
  BFN: #37911
  
http://cvs.php.net/viewvc.cgi/php-src/NEWS?r1=1.2027.2.547.2.965.2.23r2=1.2027.2.547.2.965.2.24diff_format=u
Index: php-src/NEWS
diff -u php-src/NEWS:1.2027.2.547.2.965.2.23 
php-src/NEWS:1.2027.2.547.2.965.2.24
--- php-src/NEWS:1.2027.2.547.2.965.2.23Sun Oct  7 10:35:02 2007
+++ php-src/NEWSSun Oct  7 11:51:35 2007
@@ -47,6 +47,7 @@
   (Jani)
 - Fixed bug #42069 (parse_ini_file() allows using some non-alpha numeric
   characters). (Jani)
+- Fixed bug #37911 (preg_replace_callback() ignores named groups). (Nuno)
 - Fixed bug #27372 (parse error loading browscap.ini at apache startup).
   (Jani)
 

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



[PHP-CVS] cvs: php-src /ext/pcre php_pcre.c /ext/pcre/tests bug37911.phpt

2007-10-07 Thread Nuno Lopes
nlopess Sun Oct  7 12:09:02 2007 UTC

  Modified files:  
/php-src/ext/pcre   php_pcre.c 
/php-src/ext/pcre/tests bug37911.phpt 
  Log:
  MFB: fix #37911
  http://cvs.php.net/viewvc.cgi/php-src/ext/pcre/php_pcre.c?r1=1.222r2=1.223diff_format=u
Index: php-src/ext/pcre/php_pcre.c
diff -u php-src/ext/pcre/php_pcre.c:1.222 php-src/ext/pcre/php_pcre.c:1.223
--- php-src/ext/pcre/php_pcre.c:1.222   Sun Oct  7 05:15:04 2007
+++ php-src/ext/pcre/php_pcre.c Sun Oct  7 12:09:02 2007
@@ -16,7 +16,7 @@
+--+
  */
 
-/* $Id: php_pcre.c,v 1.222 2007/10/07 05:15:04 davidw Exp $ */
+/* $Id: php_pcre.c,v 1.223 2007/10/07 12:09:02 nlopess Exp $ */
 
 /*  TODO
  *  php_pcre_replace_impl():
@@ -186,6 +186,48 @@
 }
 /* }}} */
 
+/* {{{ static make_subpats_table */
+static char **make_subpats_table(int num_subpats, int rc, pcre_cache_entry 
*pce)
+{
+   pcre_extra *extra = pce-extra;
+   int name_cnt = 0, name_size, ni = 0;
+   char *name_table;
+   unsigned short name_idx;
+   char **subpat_names = (char **)ecalloc(num_subpats, sizeof(char *));
+
+   rc = pcre_fullinfo(pce-re, extra, PCRE_INFO_NAMECOUNT, name_cnt);
+   if (rc  0) {
+   php_error_docref(NULL TSRMLS_CC, E_WARNING, Internal 
pcre_fullinfo() error %d, rc);
+   efree(subpat_names);
+   return NULL;
+   }
+   if (name_cnt  0) {
+   int rc1, rc2;
+   rc1 = pcre_fullinfo(pce-re, extra, PCRE_INFO_NAMETABLE, 
name_table);
+   rc2 = pcre_fullinfo(pce-re, extra, PCRE_INFO_NAMEENTRYSIZE, 
name_size);
+   rc = rc2 ? rc2 : rc1;
+   if (rc  0) {
+   php_error_docref(NULL TSRMLS_CC, E_WARNING, Internal 
pcre_fullinfo() error %d, rc);
+   efree(subpat_names);
+   return NULL;
+   }
+
+   while (ni++  name_cnt) {
+   name_idx = 0xff * name_table[0] + name_table[1];
+   subpat_names[name_idx] = name_table + 2;
+   if (is_numeric_string(subpat_names[name_idx], 
strlen(subpat_names[name_idx]), NULL, NULL, 0)  0) {
+   php_error_docref(NULL TSRMLS_CC, E_WARNING, 
Numeric named subpatterns are not allowed);
+   efree(subpat_names);
+   return NULL;
+   }
+   name_table += name_size;
+   }
+   }
+
+   return subpat_names;
+}
+/* }}} */
+
 /* {{{ pcre_get_compiled_regex_cache
  */
 PHPAPI pcre_cache_entry* pcre_get_compiled_regex_cache(zend_uchar utype, char 
*regex, int regex_len TSRMLS_DC)
@@ -554,7 +596,7 @@
int  g_notempty = 0;/* If the match 
should not be empty */
const char **stringlist;/* Holds list of 
subpatterns */
char*match; /* The current 
match */
-   char   **subpat_names = NULL;/* Array for named subpatterns 
*/
+   char   **subpat_names;  /* Array for named 
subpatterns */
int  i, rc;
int  subpats_order; /* Order of 
subpattern matches */
int  offset_capture;/* Capture match 
offsets: yes/no */
@@ -624,55 +666,19 @@
}
num_subpats++;
size_offsets = num_subpats * 3;
-   offsets = (int *)safe_emalloc(size_offsets, sizeof(int), 0);
 
/*
 * Build a mapping from subpattern numbers to their names. We will 
always
 * allocate the table, even though there may be no named subpatterns. 
This
 * avoids somewhat more complicated logic in the inner loops.
 */
-   subpat_names = (char **)safe_emalloc(num_subpats, sizeof(char *), 0);
-   memset(subpat_names, 0, sizeof(char *) * num_subpats);
-   {
-   int name_cnt = 0, name_size, ni = 0;
-   char *name_table;
-   unsigned short name_idx;
-
-   rc = pcre_fullinfo(pce-re, extra, PCRE_INFO_NAMECOUNT, 
name_cnt);
-   if (rc  0) {
-   php_error_docref(NULL TSRMLS_CC, E_WARNING, Internal 
pcre_fullinfo() error %d, rc);
-   efree(offsets);
-   efree(subpat_names);
-   RETURN_FALSE;
-   }
-   if (name_cnt  0) {
-   int rc1, rc2;
-   long dummy_l;
-   double dummy_d;
-   rc1 = pcre_fullinfo(pce-re, extra, 
PCRE_INFO_NAMETABLE, name_table);
-   rc2 = pcre_fullinfo(pce-re, extra, 
PCRE_INFO_NAMEENTRYSIZE, name_size);
-   rc = rc2 ? rc2 : rc1;
-   if (rc  0) {
- 

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

2007-10-07 Thread Nuno Lopes
nlopess Sun Oct  7 12:14:02 2007 UTC

  Modified files:  (Branch: PHP_5_3)
/php-src/ext/pcre   php_pcre.c 
  Log:
  fix the previous patch: the rc var doesnt need to be passed to the 
make_subpats_table()
  
http://cvs.php.net/viewvc.cgi/php-src/ext/pcre/php_pcre.c?r1=1.168.2.9.2.21.2.3r2=1.168.2.9.2.21.2.4diff_format=u
Index: php-src/ext/pcre/php_pcre.c
diff -u php-src/ext/pcre/php_pcre.c:1.168.2.9.2.21.2.3 
php-src/ext/pcre/php_pcre.c:1.168.2.9.2.21.2.4
--- php-src/ext/pcre/php_pcre.c:1.168.2.9.2.21.2.3  Sun Oct  7 11:48:27 2007
+++ php-src/ext/pcre/php_pcre.c Sun Oct  7 12:14:02 2007
@@ -16,7 +16,7 @@
+--+
  */
 
-/* $Id: php_pcre.c,v 1.168.2.9.2.21.2.3 2007/10/07 11:48:27 nlopess Exp $ */
+/* $Id: php_pcre.c,v 1.168.2.9.2.21.2.4 2007/10/07 12:14:02 nlopess Exp $ */
 
 #include php.h
 #include php_ini.h
@@ -175,10 +175,11 @@
 /* }}} */
 
 /* {{{ static make_subpats_table */
-static char **make_subpats_table(int num_subpats, int rc, pcre_cache_entry 
*pce)
+static char **make_subpats_table(int num_subpats, pcre_cache_entry *pce)
 {
pcre_extra *extra = pce-extra;
int name_cnt = 0, name_size, ni = 0;
+   int rc;
char *name_table;
unsigned short name_idx;
char **subpat_names = (char **)ecalloc(num_subpats, sizeof(char *));
@@ -588,7 +589,7 @@
 * allocate the table, even though there may be no named subpatterns. 
This
 * avoids somewhat more complicated logic in the inner loops.
 */
-   subpat_names = make_subpats_table(num_subpats, rc, pce);
+   subpat_names = make_subpats_table(num_subpats, pce);
if (!subpat_names) {
RETURN_FALSE;
}
@@ -1014,7 +1015,7 @@
 * allocate the table, even though there may be no named subpatterns. 
This
 * avoids somewhat more complicated logic in the inner loops.
 */
-   subpat_names = make_subpats_table(num_subpats, rc, pce);
+   subpat_names = make_subpats_table(num_subpats, pce);
if (!subpat_names) {
return NULL;
}

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



[PHP-CVS] cvs: php-src /ext/pcre php_pcre.c

2007-10-07 Thread Nuno Lopes
nlopess Sun Oct  7 12:14:59 2007 UTC

  Modified files:  
/php-src/ext/pcre   php_pcre.c 
  Log:
  MFB
  
http://cvs.php.net/viewvc.cgi/php-src/ext/pcre/php_pcre.c?r1=1.223r2=1.224diff_format=u
Index: php-src/ext/pcre/php_pcre.c
diff -u php-src/ext/pcre/php_pcre.c:1.223 php-src/ext/pcre/php_pcre.c:1.224
--- php-src/ext/pcre/php_pcre.c:1.223   Sun Oct  7 12:09:02 2007
+++ php-src/ext/pcre/php_pcre.c Sun Oct  7 12:14:59 2007
@@ -16,7 +16,7 @@
+--+
  */
 
-/* $Id: php_pcre.c,v 1.223 2007/10/07 12:09:02 nlopess Exp $ */
+/* $Id: php_pcre.c,v 1.224 2007/10/07 12:14:59 nlopess Exp $ */
 
 /*  TODO
  *  php_pcre_replace_impl():
@@ -187,10 +187,11 @@
 /* }}} */
 
 /* {{{ static make_subpats_table */
-static char **make_subpats_table(int num_subpats, int rc, pcre_cache_entry 
*pce)
+static char **make_subpats_table(int num_subpats, pcre_cache_entry *pce)
 {
pcre_extra *extra = pce-extra;
int name_cnt = 0, name_size, ni = 0;
+   int rc;
char *name_table;
unsigned short name_idx;
char **subpat_names = (char **)ecalloc(num_subpats, sizeof(char *));
@@ -672,7 +673,7 @@
 * allocate the table, even though there may be no named subpatterns. 
This
 * avoids somewhat more complicated logic in the inner loops.
 */
-   subpat_names = make_subpats_table(num_subpats, rc, pce);
+   subpat_names = make_subpats_table(num_subpats, pce);
if (!subpat_names) {
RETURN_FALSE;
}
@@ -1147,7 +1148,7 @@
 * allocate the table, even though there may be no named subpatterns. 
This
 * avoids somewhat more complicated logic in the inner loops.
 */
-   subpat_names = make_subpats_table(num_subpats, rc, pce);
+   subpat_names = make_subpats_table(num_subpats, pce);
if (!subpat_names) {
return 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_3) /ext/pcre php_pcre.c

2007-10-07 Thread Nuno Lopes
nlopess Sun Oct  7 12:20:11 2007 UTC

  Modified files:  (Branch: PHP_5_3)
/php-src/ext/pcre   php_pcre.c 
  Log:
  now fix the thread-safe build..
  #sorry for the noise, but I didnt commit patches to PHP for a long time..
  
http://cvs.php.net/viewvc.cgi/php-src/ext/pcre/php_pcre.c?r1=1.168.2.9.2.21.2.4r2=1.168.2.9.2.21.2.5diff_format=u
Index: php-src/ext/pcre/php_pcre.c
diff -u php-src/ext/pcre/php_pcre.c:1.168.2.9.2.21.2.4 
php-src/ext/pcre/php_pcre.c:1.168.2.9.2.21.2.5
--- php-src/ext/pcre/php_pcre.c:1.168.2.9.2.21.2.4  Sun Oct  7 12:14:02 2007
+++ php-src/ext/pcre/php_pcre.c Sun Oct  7 12:20:11 2007
@@ -16,7 +16,7 @@
+--+
  */
 
-/* $Id: php_pcre.c,v 1.168.2.9.2.21.2.4 2007/10/07 12:14:02 nlopess Exp $ */
+/* $Id: php_pcre.c,v 1.168.2.9.2.21.2.5 2007/10/07 12:20:11 nlopess Exp $ */
 
 #include php.h
 #include php_ini.h
@@ -175,7 +175,7 @@
 /* }}} */
 
 /* {{{ static make_subpats_table */
-static char **make_subpats_table(int num_subpats, pcre_cache_entry *pce)
+static char **make_subpats_table(int num_subpats, pcre_cache_entry *pce 
TSRMLS_DC)
 {
pcre_extra *extra = pce-extra;
int name_cnt = 0, name_size, ni = 0;
@@ -589,7 +589,7 @@
 * allocate the table, even though there may be no named subpatterns. 
This
 * avoids somewhat more complicated logic in the inner loops.
 */
-   subpat_names = make_subpats_table(num_subpats, pce);
+   subpat_names = make_subpats_table(num_subpats, pce TSRMLS_CC);
if (!subpat_names) {
RETURN_FALSE;
}
@@ -1015,7 +1015,7 @@
 * allocate the table, even though there may be no named subpatterns. 
This
 * avoids somewhat more complicated logic in the inner loops.
 */
-   subpat_names = make_subpats_table(num_subpats, pce);
+   subpat_names = make_subpats_table(num_subpats, pce TSRMLS_CC);
if (!subpat_names) {
return NULL;
}

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



[PHP-CVS] cvs: php-src /ext/pcre php_pcre.c

2007-10-07 Thread Nuno Lopes
nlopess Sun Oct  7 12:21:05 2007 UTC

  Modified files:  
/php-src/ext/pcre   php_pcre.c 
  Log:
  MFB: fix ZTS build
  
http://cvs.php.net/viewvc.cgi/php-src/ext/pcre/php_pcre.c?r1=1.224r2=1.225diff_format=u
Index: php-src/ext/pcre/php_pcre.c
diff -u php-src/ext/pcre/php_pcre.c:1.224 php-src/ext/pcre/php_pcre.c:1.225
--- php-src/ext/pcre/php_pcre.c:1.224   Sun Oct  7 12:14:59 2007
+++ php-src/ext/pcre/php_pcre.c Sun Oct  7 12:21:05 2007
@@ -16,7 +16,7 @@
+--+
  */
 
-/* $Id: php_pcre.c,v 1.224 2007/10/07 12:14:59 nlopess Exp $ */
+/* $Id: php_pcre.c,v 1.225 2007/10/07 12:21:05 nlopess Exp $ */
 
 /*  TODO
  *  php_pcre_replace_impl():
@@ -187,7 +187,7 @@
 /* }}} */
 
 /* {{{ static make_subpats_table */
-static char **make_subpats_table(int num_subpats, pcre_cache_entry *pce)
+static char **make_subpats_table(int num_subpats, pcre_cache_entry *pce 
TSRMLS_DC)
 {
pcre_extra *extra = pce-extra;
int name_cnt = 0, name_size, ni = 0;
@@ -673,7 +673,7 @@
 * allocate the table, even though there may be no named subpatterns. 
This
 * avoids somewhat more complicated logic in the inner loops.
 */
-   subpat_names = make_subpats_table(num_subpats, pce);
+   subpat_names = make_subpats_table(num_subpats, pce TSRMLS_CC);
if (!subpat_names) {
RETURN_FALSE;
}
@@ -1148,7 +1148,7 @@
 * allocate the table, even though there may be no named subpatterns. 
This
 * avoids somewhat more complicated logic in the inner loops.
 */
-   subpat_names = make_subpats_table(num_subpats, pce);
+   subpat_names = make_subpats_table(num_subpats, pce TSRMLS_CC);
if (!subpat_names) {
return 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_3) / NEWS /ext/pcre php_pcre.c /ext/pcre/tests bug42737.phpt

2007-10-07 Thread Nuno Lopes
nlopess Sun Oct  7 13:57:10 2007 UTC

  Added files: (Branch: PHP_5_3)
/php-src/ext/pcre/tests bug42737.phpt 

  Modified files:  
/php-srcNEWS 
/php-src/ext/pcre   php_pcre.c 
  Log:
  Fixed bug #42737 (preg_split('//u') triggers a E_NOTICE with newlines)
  
http://cvs.php.net/viewvc.cgi/php-src/NEWS?r1=1.2027.2.547.2.965.2.24r2=1.2027.2.547.2.965.2.25diff_format=u
Index: php-src/NEWS
diff -u php-src/NEWS:1.2027.2.547.2.965.2.24 
php-src/NEWS:1.2027.2.547.2.965.2.25
--- php-src/NEWS:1.2027.2.547.2.965.2.24Sun Oct  7 11:51:35 2007
+++ php-src/NEWSSun Oct  7 13:57:09 2007
@@ -43,6 +43,7 @@
   class). (Dmitry)
 - Fixed bug #42798 (__autoload() not triggered for classes used in method
   signature). (Dmitry)
+- Fixed bug #42737 (preg_split('//u') triggers a E_NOTICE with newlines). 
(Nuno)
 - Fixed bug #42657 (ini_get() returns incorrect value when default is NULL).
   (Jani)
 - Fixed bug #42069 (parse_ini_file() allows using some non-alpha numeric
http://cvs.php.net/viewvc.cgi/php-src/ext/pcre/php_pcre.c?r1=1.168.2.9.2.21.2.5r2=1.168.2.9.2.21.2.6diff_format=u
Index: php-src/ext/pcre/php_pcre.c
diff -u php-src/ext/pcre/php_pcre.c:1.168.2.9.2.21.2.5 
php-src/ext/pcre/php_pcre.c:1.168.2.9.2.21.2.6
--- php-src/ext/pcre/php_pcre.c:1.168.2.9.2.21.2.5  Sun Oct  7 12:20:11 2007
+++ php-src/ext/pcre/php_pcre.c Sun Oct  7 13:57:10 2007
@@ -16,7 +16,7 @@
+--+
  */
 
-/* $Id: php_pcre.c,v 1.168.2.9.2.21.2.5 2007/10/07 12:20:11 nlopess Exp $ */
+/* $Id: php_pcre.c,v 1.168.2.9.2.21.2.6 2007/10/07 13:57:10 nlopess Exp $ */
 
 #include php.h
 #include php_ini.h
@@ -1528,7 +1528,7 @@
if (re_bump == NULL) {
int dummy;
 
-   if ((re_bump = 
pcre_get_compiled_regex(/./u, extra_bump, dummy TSRMLS_CC)) == NULL) {
+   if ((re_bump = 
pcre_get_compiled_regex(/./us, extra_bump, dummy TSRMLS_CC)) == NULL) {
RETURN_FALSE;
}
}

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

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



[PHP-CVS] cvs: php-src /ext/pcre/tests bug42737.phpt

2007-10-07 Thread Nuno Lopes
nlopess Sun Oct  7 14:00:20 2007 UTC

  Modified files:  
/php-src/ext/pcre/tests bug42737.phpt 
  Log:
  add test for bug #42737.
  HEAD didnt have this bug, as it uses a smarter way to iterate over utf-8 chars
  
http://cvs.php.net/viewvc.cgi/php-src/ext/pcre/tests/bug42737.phpt?r1=1.1r2=1.2diff_format=u
Index: php-src/ext/pcre/tests/bug42737.phpt
diff -u /dev/null php-src/ext/pcre/tests/bug42737.phpt:1.2
--- /dev/null   Sun Oct  7 14:00:20 2007
+++ php-src/ext/pcre/tests/bug42737.phptSun Oct  7 14:00:20 2007
@@ -0,0 +1,19 @@
+--TEST--
+Bug #42737 (preg_split('//u') triggers a E_NOTICE with newlines)
+--FILE--
+?php
+
+$string = chr(13).chr(10);
+
+$array = preg_split('//u', $string, - 1, PREG_SPLIT_NO_EMPTY);
+
+var_dump(array_map('ord', $array));
+
+?
+--EXPECT--
+array(2) {
+  [0]=
+  int(13)
+  [1]=
+  int(10)
+}

-- 
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 file.c /main/streams plain_wrapper.c

2007-11-12 Thread Nuno Lopes

Hi Ilia,



+ char mode[3] = wb;

+ if (flags  PHP_FILE_APPEND) {
+ mode[0] = 'a';
+ } else if (flags  LOCK_EX) {
+ mode[0] = 'c';


uhm, I think this assignment isn't needed, as the variable should already 
contain the '\0' from the initilization above.

+ mode[2] = '\0';



probably you meant == 'c' here

+ if (mode[0] = 'c') {
+ php_stream_truncate_set_size(stream, 0);
+ }



Nuno 


--
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_firebird .cvsignore

2007-11-16 Thread Nuno Lopes
nlopess Fri Nov 16 12:17:39 2007 UTC

  Modified files:  (Branch: PHP_5_3)
/php-src/ext/pdo_firebird   .cvsignore 
  Log:
  ignore gcov files
  
http://cvs.php.net/viewvc.cgi/php-src/ext/pdo_firebird/.cvsignore?r1=1.1r2=1.1.6.1diff_format=u
Index: php-src/ext/pdo_firebird/.cvsignore
diff -u php-src/ext/pdo_firebird/.cvsignore:1.1 
php-src/ext/pdo_firebird/.cvsignore:1.1.6.1
--- php-src/ext/pdo_firebird/.cvsignore:1.1 Tue Jun 14 13:26:07 2005
+++ php-src/ext/pdo_firebird/.cvsignore Fri Nov 16 12:17:38 2007
@@ -1,4 +1,6 @@
 .deps
+*.gcno
+*.gcda
 *.lo
 *.la
 .*.swp

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



[PHP-CVS] cvs: php-src /ext/pdo_firebird .cvsignore

2007-11-16 Thread Nuno Lopes
nlopess Fri Nov 16 12:20:57 2007 UTC

  Modified files:  
/php-src/ext/pdo_firebird   .cvsignore 
  Log:
  ignore gcov files
  
http://cvs.php.net/viewvc.cgi/php-src/ext/pdo_firebird/.cvsignore?r1=1.1r2=1.2diff_format=u
Index: php-src/ext/pdo_firebird/.cvsignore
diff -u php-src/ext/pdo_firebird/.cvsignore:1.1 
php-src/ext/pdo_firebird/.cvsignore:1.2
--- php-src/ext/pdo_firebird/.cvsignore:1.1 Tue Jun 14 13:26:07 2005
+++ php-src/ext/pdo_firebird/.cvsignore Fri Nov 16 12:20:57 2007
@@ -1,4 +1,6 @@
 .deps
+*.gcno
+*.gcda
 *.lo
 *.la
 .*.swp


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



Re: [PHP-CVS] cvs: php-src / run-tests.php

2007-12-12 Thread Nuno Lopes

Ah you are fast (less than 24 hours :)! Thank you Tony for the patch.
Can you please also merge it to PHP 5.2, so that I can upgrade valgrind in 
the gcov machine?


Thanks,
Nuno


- Original Message - 
From: Antony Dovgal [EMAIL PROTECTED]

To: php-cvs@lists.php.net
Sent: Wednesday, December 12, 2007 9:20 AM
Subject: [PHP-CVS] cvs: php-src / run-tests.php



tony2001 Wed Dec 12 09:20:42 2007 UTC

 Modified files:
   /php-src run-tests.php
 Log:
 add support for Valgrind 3.3.0 (which doesn't have --log-file-exactly 
option)



http://cvs.php.net/viewvc.cgi/php-src/run-tests.php?r1=1.332r2=1.333diff_format=u
Index: php-src/run-tests.php
diff -u php-src/run-tests.php:1.332 php-src/run-tests.php:1.333
--- php-src/run-tests.php:1.332 Wed Nov 21 08:20:11 2007
+++ php-src/run-tests.php Wed Dec 12 09:20:41 2007
@@ -24,7 +24,7 @@

+--+
 */

-/* $Id: run-tests.php,v 1.332 2007/11/21 08:20:11 jani Exp $ */
+/* $Id: run-tests.php,v 1.333 2007/12/12 09:20:41 tony2001 Exp $ */

/* Sanity check to ensure that pcre extension needed by this script is 
available.
 * In the event it is not, print a nice error message indicating that this 
script will

@@ -76,6 +76,8 @@
$cwd = getcwd();
set_time_limit(0);

+$valgrind_version = 0;
+
// delete as much output buffers as possible
while(@ob_end_clean());
if (ob_get_level()) echo Not all buffers were deleted.\n;
@@ -408,7 +410,7 @@
 $html_output = is_resource($html_file);
 break;
 case '--version':
- echo '$Revision: 1.332 $'.\n;
+ echo '$Revision: 1.333 $'.\n;
 exit(1);
 default:
 echo Illegal switch specified!\n;
@@ -972,6 +974,7 @@
 global $leak_check, $temp_source, $temp_target, $cfg, $environment;
 global $no_clean;
 global $unicode_and_native;
+ global $valgrind_version;

 $temp_filenames = null;
 $org_file = $file;
@@ -1441,7 +1444,26 @@

 if ($leak_check) {
 $env['USE_ZEND_ALLOC'] = '0';
- $cmd = 
valgrind -q --tool=memcheck --trace-children=yes --log-file-exactly=$memcheck_filename 
$cmd;

+ if (!$valgrind_version) {
+ $valgrind_cmd = valgrind --version;
+ $out = system_with_timeout($valgrind_cmd);
+ $replace_count = 0;
+
+ if (!$out) {
+ error(Valgrind returned no version info, cannot proceed.\nPlease check 
if Valgrind is installed.);

+ } else {
+ $valgrind_version = 
preg_replace(/valgrind-([0-9])\.([0-9])\.([0-9]+)(\s+)/, '$1$2$3', $out, 
1, $replace_count);

+ if ($replace_count != 1 || !is_numeric($valgrind_version)) {
+ error(Valgrind returned invalid version info (\$out\), cannot 
proceed.);

+ }
+ }
+ }
+ if ($valgrind_version = 330) {
+ /* valgrind 3.3.0+ doesn't have --log-file-exactly option */
+ $cmd = 
valgrind -q --tool=memcheck --trace-children=yes --log-file=$memcheck_filename 
$cmd;

+ } else {
+ $cmd = 
valgrind -q --tool=memcheck --trace-children=yes --log-file-exactly=$memcheck_filename 
$cmd;

+ }
 } else {
 $env['USE_ZEND_ALLOC'] = '1';
 } 


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



Re: [PHP-CVS] cvs: php-src / run-tests.php

2007-12-12 Thread Nuno Lopes

Thank you :)
Nuno

P.S.: I'll upgrade valgrind in the gcov box later next week

- Original Message - 

On 12.12.2007 23:13, Nuno Lopes wrote:

Ah you are fast (less than 24 hours :)! Thank you Tony for the patch.


Hehe, no problem =)

Can you please also merge it to PHP 5.2, so that I can upgrade valgrind 
in

the gcov machine?


Sure.

--
Wbr,
Antony Dovgal 


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



Re: [PHP-CVS] cvs: php-src / run-tests.php

2007-12-24 Thread Nuno Lopes

@@ -1600,7 +1600,7 @@
 $wanted_re = str_replace('%i', '[+-]?\d+', $wanted_re);
 $wanted_re = str_replace('%d', '\d+', $wanted_re);
 $wanted_re = str_replace('%x', '[0-9a-fA-F]+', $wanted_re);
- $wanted_re = str_replace('%f', '[+-]?\.?\d+\.?\d*(?:E[+-]?\d+)?', 
$wanted_re);
+ $wanted_re = str_replace('%f', '[+-]?\.?\d+\.?\d*(?:E|e[+-]?\d+)?', 
$wanted_re);

 $wanted_re = str_replace('%c', '.', $wanted_re);
 // %f allows two points -.0.0 but that is the best *simple* expression



Please use [Ee] there instead of E|e. That is much more intuitive on what 
it'll match.
Nuno 


--
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/gmp/tests 011.phpt 026.phpt

2007-12-27 Thread Nuno Lopes
nlopess Thu Dec 27 16:05:01 2007 UTC

  Modified files:  (Branch: PHP_5_3)
/php-src/ext/gmp/tests  011.phpt 026.phpt 
  Log:
  fix tests
  
http://cvs.php.net/viewvc.cgi/php-src/ext/gmp/tests/011.phpt?r1=1.1.2.5.2.1r2=1.1.2.5.2.2diff_format=u
Index: php-src/ext/gmp/tests/011.phpt
diff -u php-src/ext/gmp/tests/011.phpt:1.1.2.5.2.1 
php-src/ext/gmp/tests/011.phpt:1.1.2.5.2.2
--- php-src/ext/gmp/tests/011.phpt:1.1.2.5.2.1  Thu Nov  1 00:46:12 2007
+++ php-src/ext/gmp/tests/011.phpt  Thu Dec 27 16:05:00 2007
@@ -39,7 +39,7 @@
 echo Done\n;
 ?
 --EXPECTF--
-Warning: gmp_divexact() expects exactly 2 parameters, 0 given in %s on line %d
+Warning: gmp_divexact() expects exactly 2 parameters, 3 given in %s on line %d
 NULL
 
 Warning: gmp_divexact() expects exactly 2 parameters, 0 given in %s on line %d
http://cvs.php.net/viewvc.cgi/php-src/ext/gmp/tests/026.phpt?r1=1.1.2.3.2.2r2=1.1.2.3.2.3diff_format=u
Index: php-src/ext/gmp/tests/026.phpt
diff -u php-src/ext/gmp/tests/026.phpt:1.1.2.3.2.2 
php-src/ext/gmp/tests/026.phpt:1.1.2.3.2.3
--- php-src/ext/gmp/tests/026.phpt:1.1.2.3.2.2  Thu Nov  1 09:25:11 2007
+++ php-src/ext/gmp/tests/026.phpt  Thu Dec 27 16:05:00 2007
@@ -13,7 +13,7 @@
 var_dump(gmp_cmp(0,345355));
 
 $n = gmp_init(827278512385463739);
-var_dump(gmp_cmp(0,$n));
+var_dump(gmp_cmp(0,$n)  0);
 $n1 = gmp_init(827278512385463739);
 var_dump(gmp_cmp($n1,$n));
 
@@ -31,7 +31,7 @@
 int(0)
 int(1)
 int(-1)
-int(-1)
+bool(true)
 int(0)
 
 Warning: gmp_cmp() expects exactly 2 parameters, 3 given in %s on line %d

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



[PHP-CVS] cvs: php-src /ext/gmp/tests 026.phpt

2007-12-27 Thread Nuno Lopes
nlopess Thu Dec 27 16:05:59 2007 UTC

  Modified files:  
/php-src/ext/gmp/tests  026.phpt 
  Log:
  MFB: fix tests
  
http://cvs.php.net/viewvc.cgi/php-src/ext/gmp/tests/026.phpt?r1=1.3r2=1.4diff_format=u
Index: php-src/ext/gmp/tests/026.phpt
diff -u php-src/ext/gmp/tests/026.phpt:1.3 php-src/ext/gmp/tests/026.phpt:1.4
--- php-src/ext/gmp/tests/026.phpt:1.3  Tue Nov  6 14:31:07 2007
+++ php-src/ext/gmp/tests/026.phpt  Thu Dec 27 16:05:58 2007
@@ -13,7 +13,7 @@
 var_dump(gmp_cmp(0,345355));
 
 $n = gmp_init(827278512385463739);
-var_dump(gmp_cmp(0,$n));
+var_dump(gmp_cmp(0,$n)  0);
 $n1 = gmp_init(827278512385463739);
 var_dump(gmp_cmp($n1,$n));
 
@@ -31,7 +31,7 @@
 int(0)
 int(1)
 int(-1)
-int(-1)
+bool(true)
 int(0)
 
 Warning: gmp_cmp() expects exactly 2 parameters, 3 given in %s on line %d

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



[PHP-CVS] cvs: php-src /ext/com_dotnet php_com_dotnet.h /ext/ctype php_ctype.h /ext/filter php_filter.h /ext/gmp php_gmp.h /ext/json php_json.h /ext/mime_magic php_mime_magic.h /ext/mssql php_ms

2008-01-03 Thread Nuno Lopes
nlopess Thu Jan  3 16:18:29 2008 UTC

  Modified files:  
/php-src/ext/com_dotnet php_com_dotnet.h 
/php-src/ext/ctype  php_ctype.h 
/php-src/ext/filter php_filter.h 
/php-src/ext/gmpphp_gmp.h 
/php-src/ext/json   php_json.h 
/php-src/ext/mime_magic php_mime_magic.h 
/php-src/ext/mssql  php_mssql.h 
/php-src/ext/oci8   php_oci8.h 
/php-src/ext/pcntl  php_pcntl.h 
/php-src/ext/pdo_dblib  php_pdo_dblib.h 
/php-src/ext/pdo_firebird   php_pdo_firebird.h 
/php-src/ext/pdo_mysql  php_pdo_mysql.h 
/php-src/ext/pdo_ociphp_pdo_oci.h 
/php-src/ext/pdo_odbc   php_pdo_odbc.h 
/php-src/ext/pdo_pgsql  php_pdo_pgsql.h 
/php-src/ext/pdo_sqlite php_pdo_sqlite.h 
/php-src/ext/shmop  php_shmop.h 
/php-src/ext/simplexml  php_simplexml.h 
/php-src/ext/soap   php_soap.h 
/php-src/ext/socketsphp_sockets.h 
/php-src/ext/sqlite php_sqlite.h 
/php-src/ext/tokenizer  php_tokenizer.h 
/php-src/ext/xmlphp_xml.h 
/php-src/ext/xmlreader  php_xmlreader.h 
/php-src/ext/xmlrpc php_xmlrpc.h 
/php-src/ext/xslphp_xsl.h 
  Log:
  MFB: remove unused PHP_EXTNAME_API macros.
  #in preparation for the gcc 4 visibility patch
  http://cvs.php.net/viewvc.cgi/php-src/ext/com_dotnet/php_com_dotnet.h?r1=1.9r2=1.10diff_format=u
Index: php-src/ext/com_dotnet/php_com_dotnet.h
diff -u php-src/ext/com_dotnet/php_com_dotnet.h:1.9 
php-src/ext/com_dotnet/php_com_dotnet.h:1.10
--- php-src/ext/com_dotnet/php_com_dotnet.h:1.9 Mon Dec 31 07:12:08 2007
+++ php-src/ext/com_dotnet/php_com_dotnet.h Thu Jan  3 16:18:27 2008
@@ -16,7 +16,7 @@
+--+
  */
 
-/* $Id: php_com_dotnet.h,v 1.9 2007/12/31 07:12:08 sebastian Exp $ */
+/* $Id: php_com_dotnet.h,v 1.10 2008/01/03 16:18:27 nlopess Exp $ */
 
 #ifndef PHP_COM_DOTNET_H
 #define PHP_COM_DOTNET_H
@@ -24,12 +24,6 @@
 extern zend_module_entry com_dotnet_module_entry;
 #define phpext_com_dotnet_ptr com_dotnet_module_entry
 
-#ifdef PHP_WIN32
-# define PHP_COM_DOTNET_API __declspec(dllexport)
-#else
-# define PHP_COM_DOTNET_API
-#endif
-
 #ifdef ZTS
 #include TSRM.h
 #endif
http://cvs.php.net/viewvc.cgi/php-src/ext/ctype/php_ctype.h?r1=1.18r2=1.19diff_format=u
Index: php-src/ext/ctype/php_ctype.h
diff -u php-src/ext/ctype/php_ctype.h:1.18 php-src/ext/ctype/php_ctype.h:1.19
--- php-src/ext/ctype/php_ctype.h:1.18  Mon Dec 31 07:12:08 2007
+++ php-src/ext/ctype/php_ctype.h   Thu Jan  3 16:18:27 2008
@@ -24,12 +24,6 @@
 extern zend_module_entry ctype_module_entry;
 #define phpext_ctype_ptr ctype_module_entry
 
-#ifdef PHP_WIN32
-#define PHP_CTYPE_API __declspec(dllexport)
-#else
-#define PHP_CTYPE_API
-#endif
-
 #else
 
 #define phpext_ctype_ptr NULL
http://cvs.php.net/viewvc.cgi/php-src/ext/filter/php_filter.h?r1=1.14r2=1.15diff_format=u
Index: php-src/ext/filter/php_filter.h
diff -u php-src/ext/filter/php_filter.h:1.14 
php-src/ext/filter/php_filter.h:1.15
--- php-src/ext/filter/php_filter.h:1.14Mon Dec 31 07:12:09 2007
+++ php-src/ext/filter/php_filter.h Thu Jan  3 16:18:27 2008
@@ -17,7 +17,7 @@
   +--+
 */
 
-/* $Id: php_filter.h,v 1.14 2007/12/31 07:12:09 sebastian Exp $ */
+/* $Id: php_filter.h,v 1.15 2008/01/03 16:18:27 nlopess Exp $ */
 
 #ifndef PHP_FILTER_H
 #define PHP_FILTER_H
@@ -33,12 +33,6 @@
 extern zend_module_entry filter_module_entry;
 #define phpext_filter_ptr filter_module_entry
 
-#ifdef PHP_WIN32
-#define PHP_FILTER_API __declspec(dllexport)
-#else
-#define PHP_FILTER_API
-#endif
-
 #ifdef ZTS
 #include TSRM.h
 #endif
http://cvs.php.net/viewvc.cgi/php-src/ext/gmp/php_gmp.h?r1=1.18r2=1.19diff_format=u
Index: php-src/ext/gmp/php_gmp.h
diff -u php-src/ext/gmp/php_gmp.h:1.18 php-src/ext/gmp/php_gmp.h:1.19
--- php-src/ext/gmp/php_gmp.h:1.18  Mon Dec 31 07:12:10 2007
+++ php-src/ext/gmp/php_gmp.h   Thu Jan  3 16:18:27 2008
@@ -26,12 +26,6 @@
 extern zend_module_entry gmp_module_entry;
 #define phpext_gmp_ptr gmp_module_entry
 
-#ifdef ZEND_WIN32
-#define GMP_API __declspec(dllexport)
-#else
-#define GMP_API
-#endif
-
 ZEND_MODULE_STARTUP_D(gmp);
 ZEND_MODULE_DEACTIVATE_D(gmp);
 ZEND_MODULE_INFO_D(gmp);
http://cvs.php.net/viewvc.cgi/php-src/ext/json/php_json.h?r1=1.11r2=1.12diff_format=u
Index: php-src/ext/json/php_json.h
diff -u php-src/ext/json/php_json.h:1.11 php-src/ext/json/php_json.h:1.12
--- php-src/ext/json/php_json.h:1.11Mon Dec 31 07:12:10 2007
+++ php-src/ext/json/php_json.h Thu Jan  3 16:18:27 2008
@@ -16,7 +16,7 @@
   +--+
 */
 
-/* $Id: php_json.h,v 1.11 2007/12/31 07:12:10 sebastian Exp $ */
+/* $Id: php_json.h,v 1.12 2008/01/03 16:18:27 nlopess Exp $ */
 
 #ifndef PHP_JSON_H
 #define PHP_JSON_H
@@ -26,12 +26,6 @@
 extern zend_module_entry json_module_entry;
 #define 

[PHP-CVS] cvs: php-src(PHP_5_3) /ext/com_dotnet php_com_dotnet.h /ext/ctype php_ctype.h /ext/filter php_filter.h /ext/gmp php_gmp.h /ext/json php_json.h /ext/mime_magic php_mime_magic.h /ext/mss

2008-01-03 Thread Nuno Lopes
nlopess Thu Jan  3 16:20:34 2008 UTC

  Modified files:  (Branch: PHP_5_3)
/php-src/ext/com_dotnet php_com_dotnet.h 
/php-src/ext/ctype  php_ctype.h 
/php-src/ext/filter php_filter.h 
/php-src/ext/gmpphp_gmp.h 
/php-src/ext/json   php_json.h 
/php-src/ext/mime_magic php_mime_magic.h 
/php-src/ext/mssql  php_mssql.h 
/php-src/ext/ncursesphp_ncurses.h 
/php-src/ext/oci8   php_oci8.h 
/php-src/ext/pcntl  php_pcntl.h 
/php-src/ext/pdo_dblib  php_pdo_dblib.h 
/php-src/ext/pdo_firebird   php_pdo_firebird.h 
/php-src/ext/pdo_mysql  php_pdo_mysql.h 
/php-src/ext/pdo_ociphp_pdo_oci.h 
/php-src/ext/pdo_odbc   php_pdo_odbc.h 
/php-src/ext/pdo_pgsql  php_pdo_pgsql.h 
/php-src/ext/pdo_sqlite php_pdo_sqlite.h 
/php-src/ext/shmop  php_shmop.h 
/php-src/ext/simplexml  php_simplexml.h 
/php-src/ext/soap   php_soap.h 
/php-src/ext/socketsphp_sockets.h 
/php-src/ext/sqlite php_sqlite.h 
/php-src/ext/tokenizer  php_tokenizer.h 
/php-src/ext/xmlphp_xml.h 
/php-src/ext/xmlreader  php_xmlreader.h 
/php-src/ext/xmlrpc php_xmlrpc.h 
/php-src/ext/xslphp_xsl.h 
  Log:
  remove unused PHP_EXTNAME_API macros.
  #in preparation for the gcc 4 visibility patch
  http://cvs.php.net/viewvc.cgi/php-src/ext/com_dotnet/php_com_dotnet.h?r1=1.5.2.1.2.2.2.1r2=1.5.2.1.2.2.2.2diff_format=u
Index: php-src/ext/com_dotnet/php_com_dotnet.h
diff -u php-src/ext/com_dotnet/php_com_dotnet.h:1.5.2.1.2.2.2.1 
php-src/ext/com_dotnet/php_com_dotnet.h:1.5.2.1.2.2.2.2
--- php-src/ext/com_dotnet/php_com_dotnet.h:1.5.2.1.2.2.2.1 Mon Dec 31 
07:17:06 2007
+++ php-src/ext/com_dotnet/php_com_dotnet.h Thu Jan  3 16:20:30 2008
@@ -16,7 +16,7 @@
+--+
  */
 
-/* $Id: php_com_dotnet.h,v 1.5.2.1.2.2.2.1 2007/12/31 07:17:06 sebastian Exp $ 
*/
+/* $Id: php_com_dotnet.h,v 1.5.2.1.2.2.2.2 2008/01/03 16:20:30 nlopess Exp $ */
 
 #ifndef PHP_COM_DOTNET_H
 #define PHP_COM_DOTNET_H
@@ -24,12 +24,6 @@
 extern zend_module_entry com_dotnet_module_entry;
 #define phpext_com_dotnet_ptr com_dotnet_module_entry
 
-#ifdef PHP_WIN32
-# define PHP_COM_DOTNET_API __declspec(dllexport)
-#else
-# define PHP_COM_DOTNET_API
-#endif
-
 #ifdef ZTS
 #include TSRM.h
 #endif
http://cvs.php.net/viewvc.cgi/php-src/ext/ctype/php_ctype.h?r1=1.12.2.1.2.4.2.1r2=1.12.2.1.2.4.2.2diff_format=u
Index: php-src/ext/ctype/php_ctype.h
diff -u php-src/ext/ctype/php_ctype.h:1.12.2.1.2.4.2.1 
php-src/ext/ctype/php_ctype.h:1.12.2.1.2.4.2.2
--- php-src/ext/ctype/php_ctype.h:1.12.2.1.2.4.2.1  Mon Dec 31 07:17:06 2007
+++ php-src/ext/ctype/php_ctype.h   Thu Jan  3 16:20:30 2008
@@ -24,12 +24,6 @@
 extern zend_module_entry ctype_module_entry;
 #define phpext_ctype_ptr ctype_module_entry
 
-#ifdef PHP_WIN32
-#define PHP_CTYPE_API __declspec(dllexport)
-#else
-#define PHP_CTYPE_API
-#endif
-
 #else
 
 #define phpext_ctype_ptr NULL
http://cvs.php.net/viewvc.cgi/php-src/ext/filter/php_filter.h?r1=1.10.2.2.2.1r2=1.10.2.2.2.2diff_format=u
Index: php-src/ext/filter/php_filter.h
diff -u php-src/ext/filter/php_filter.h:1.10.2.2.2.1 
php-src/ext/filter/php_filter.h:1.10.2.2.2.2
--- php-src/ext/filter/php_filter.h:1.10.2.2.2.1Mon Dec 31 07:17:08 2007
+++ php-src/ext/filter/php_filter.h Thu Jan  3 16:20:31 2008
@@ -17,7 +17,7 @@
   +--+
 */
 
-/* $Id: php_filter.h,v 1.10.2.2.2.1 2007/12/31 07:17:08 sebastian Exp $ */
+/* $Id: php_filter.h,v 1.10.2.2.2.2 2008/01/03 16:20:31 nlopess Exp $ */
 
 #ifndef PHP_FILTER_H
 #define PHP_FILTER_H
@@ -33,12 +33,6 @@
 extern zend_module_entry filter_module_entry;
 #define phpext_filter_ptr filter_module_entry
 
-#ifdef PHP_WIN32
-#define PHP_FILTER_API __declspec(dllexport)
-#else
-#define PHP_FILTER_API
-#endif
-
 #ifdef ZTS
 #include TSRM.h
 #endif
http://cvs.php.net/viewvc.cgi/php-src/ext/gmp/php_gmp.h?r1=1.12.2.1.2.3.2.2r2=1.12.2.1.2.3.2.3diff_format=u
Index: php-src/ext/gmp/php_gmp.h
diff -u php-src/ext/gmp/php_gmp.h:1.12.2.1.2.3.2.2 
php-src/ext/gmp/php_gmp.h:1.12.2.1.2.3.2.3
--- php-src/ext/gmp/php_gmp.h:1.12.2.1.2.3.2.2  Mon Dec 31 07:17:08 2007
+++ php-src/ext/gmp/php_gmp.h   Thu Jan  3 16:20:31 2008
@@ -26,12 +26,6 @@
 extern zend_module_entry gmp_module_entry;
 #define phpext_gmp_ptr gmp_module_entry
 
-#ifdef ZEND_WIN32
-#define GMP_API __declspec(dllexport)
-#else
-#define GMP_API
-#endif
-
 ZEND_MODULE_STARTUP_D(gmp);
 ZEND_MODULE_DEACTIVATE_D(gmp);
 ZEND_MODULE_INFO_D(gmp);
http://cvs.php.net/viewvc.cgi/php-src/ext/json/php_json.h?r1=1.8.2.2.2.1r2=1.8.2.2.2.2diff_format=u
Index: php-src/ext/json/php_json.h
diff -u php-src/ext/json/php_json.h:1.8.2.2.2.1 
php-src/ext/json/php_json.h:1.8.2.2.2.2
--- php-src/ext/json/php_json.h:1.8.2.2.2.1 Mon Dec 31 07:17:09 2007
+++ php-src/ext/json/php_json.h Thu Jan  3 

Re: [PHP-CVS] cvs: php-src / run-tests.php

2008-01-05 Thread Nuno Lopes
Please also update http://qa.php.net/write-test.php (in cvs, under the qaweb 
module).


Thanks,
Nuno


- Original Message - 
From: Greg Beaver [EMAIL PROTECTED]

To: php-cvs@lists.php.net
Sent: Saturday, January 05, 2008 9:04 PM
Subject: [PHP-CVS] cvs: php-src / run-tests.php



cellog Sat Jan  5 21:04:55 2008 UTC

 Modified files:
   /php-src run-tests.php
 Log:
 implement --FILE_EXTERNAL-- section for using an external file 
as --FILE--, use CGI for --EXPECTHEADERS--, fix --POST_RAW--


http://cvs.php.net/viewvc.cgi/php-src/run-tests.php?r1=1.337r2=1.338diff_format=u
Index: php-src/run-tests.php
diff -u php-src/run-tests.php:1.337 php-src/run-tests.php:1.338
--- php-src/run-tests.php:1.337 Tue Jan  1 06:22:15 2008
+++ php-src/run-tests.php Sat Jan  5 21:04:55 2008
@@ -24,7 +24,7 @@

+--+
 */

-/* $Id: run-tests.php,v 1.337 2008/01/01 06:22:15 sebastian Exp $ */
+/* $Id: run-tests.php,v 1.338 2008/01/05 21:04:55 cellog Exp $ */

/* Sanity check to ensure that pcre extension needed by this script is 
available.
 * In the event it is not, print a nice error message indicating that this 
script will

@@ -415,7 +415,7 @@
 $html_output = is_resource($html_file);
 break;
 case '--version':
- echo '$Revision: 1.337 $'.\n;
+ echo '$Revision: 1.338 $'.\n;
 exit(1);
 default:
 echo Illegal switch specified!\n;
@@ -1056,7 +1056,7 @@
 if (preg_match('/^--([_A-Z]+)--/', $line, $r)) {
 $section = $r[1];
 $section_text[$section] = '';
- $secfile = $section == 'FILE' || $section == 'FILEEOF';
+ $secfile = $section == 'FILE' || $section == 'FILEEOF' || $section == 
'FILE_EXTERNAL';

 $secdone = false;
 continue;
 }
@@ -1082,7 +1082,7 @@
 $borked = false;
 }
 } else {
- if (@count($section_text['FILE']) + @count($section_text['FILEEOF']) != 
1) {
+ if (@count($section_text['FILE']) + @count($section_text['FILEEOF']) + 
@count($section_text['FILE_EXTERNAL']) != 1) {

 $bork_info = missing section --FILE--;
 $borked = true;
 }
@@ -1090,6 +1090,17 @@
 $section_text['FILE'] = preg_replace(/[\r\n]+$/, '', 
$section_text['FILEEOF']);

 unset($section_text['FILEEOF']);
 }
+ if (@count($section_text['FILE_EXTERNAL']) == 1) {
+ // don't allow tests to retrieve files from anywhere but this 
subdirectory
+ $section_text['FILE_EXTERNAL'] = dirname($file) . '/' . 
trim(str_replace('..', '', $section_text['FILE_EXTERNAL']));

+ if (@file_exists($section_text['FILE_EXTERNAL'])) {
+ $section_text['FILE'] = 
file_get_contents($section_text['FILE_EXTERNAL']);

+ unset($section_text['FILE_EXTERNAL']);
+ } else {
+ $bork_info = could not load --FILE_EXTERNAL--  . dirname($file) . '/' 
. trim($section_text['FILE_EXTERNAL']);

+ $borked = true;
+ }
+ }
 if ((@count($section_text['EXPECT']) + @count($section_text['EXPECTF']) + 
@count($section_text['EXPECTREGEX'])) != 1) {
 $bork_info = missing section --EXPECT--, --EXPECTF--  
or --EXPECTREGEX--;

 $borked = true;
@@ -1120,7 +1131,7 @@
 $tested = trim($section_text['TEST']);

 /* For GET/POST tests, check if cgi sapi is available and if it is, use 
it. */
- if (!empty($section_text['GET']) || !empty($section_text['POST']) || 
!empty($section_text['POST_RAW']) || !empty($section_text['COOKIE'])) {
+ if (!empty($section_text['GET']) || !empty($section_text['POST']) || 
!empty($section_text['POST_RAW']) || !empty($section_text['COOKIE']) || 
!empty($section_text['EXPECTHEADERS'])) {

 if (isset($php_cgi)) {
 $old_php = $php;
 $php = $php_cgi .' -C ';
@@ -1418,12 +1429,15 @@
 $raw_lines = explode(\n, $post);

 $request = '';
+ $started = false;
 foreach ($raw_lines as $line) {
 if (empty($env['CONTENT_TYPE'])  preg_match('/^Content-Type:(.*)/i', 
$line, $res)) {

 $env['CONTENT_TYPE'] = trim(str_replace(\r, '', $res[1]));
 continue;
 }
- $request .= $line . \n;
+ if ($started) $request .= \n;
+ $started = true;
+ $request .= $line;
 }

 $env['CONTENT_LENGTH'] = strlen($request); 


--
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 /ext/pcre php_pcre.c /ext/pcre/tests bug42945.phpt

2008-01-13 Thread Nuno Lopes
nlopess Sun Jan 13 14:44:29 2008 UTC

  Added files: (Branch: PHP_5_3)
/php-src/ext/pcre/tests bug42945.phpt 

  Modified files:  
/php-srcNEWS 
/php-src/ext/pcre   php_pcre.c 
  Log:
  Fixed bug #42945 (preg_split() swallows part of the string)
  
http://cvs.php.net/viewvc.cgi/php-src/NEWS?r1=1.2027.2.547.2.965.2.68r2=1.2027.2.547.2.965.2.69diff_format=u
Index: php-src/NEWS
diff -u php-src/NEWS:1.2027.2.547.2.965.2.68 
php-src/NEWS:1.2027.2.547.2.965.2.69
--- php-src/NEWS:1.2027.2.547.2.965.2.68Sun Jan 13 12:44:56 2008
+++ php-src/NEWSSun Jan 13 14:44:28 2008
@@ -71,6 +71,7 @@
 - Fixed bug #43128 (Very long class name causes segfault). (Dmitry)
 - Fixed bug #42952 (soap cache file is created with insecure permissions).
   (Dmitry)
+- Fixed bug #42945 (preg_split() swallows part of the string). (Nuno)
 - Fixed bug #42868 (Floats cast to integer produce unpredictable results).
   (Zoe Slattery)
 - Fixed bug #42848 (Status: header incorrect under FastCGI). (Dmitry)
http://cvs.php.net/viewvc.cgi/php-src/ext/pcre/php_pcre.c?r1=1.168.2.9.2.21.2.8r2=1.168.2.9.2.21.2.9diff_format=u
Index: php-src/ext/pcre/php_pcre.c
diff -u php-src/ext/pcre/php_pcre.c:1.168.2.9.2.21.2.8 
php-src/ext/pcre/php_pcre.c:1.168.2.9.2.21.2.9
--- php-src/ext/pcre/php_pcre.c:1.168.2.9.2.21.2.8  Mon Dec 31 07:17:11 2007
+++ php-src/ext/pcre/php_pcre.c Sun Jan 13 14:44:29 2008
@@ -16,7 +16,7 @@
+--+
  */
 
-/* $Id: php_pcre.c,v 1.168.2.9.2.21.2.8 2007/12/31 07:17:11 sebastian Exp $ */
+/* $Id: php_pcre.c,v 1.168.2.9.2.21.2.9 2008/01/13 14:44:29 nlopess Exp $ */
 
 #include php.h
 #include php_ini.h
@@ -1562,7 +1562,9 @@
}
 
 
-   if (!no_empty || start_offset != subject_len)
+   start_offset = last_match - subject; /* the offset might have been 
incremented, but without further successful matches */
+
+   if (!no_empty || start_offset  subject_len)
{
if (offset_capture) {
/* Add the last (match, offset) pair to the return 
value */

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

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



[PHP-CVS] cvs: php-src /ext/pcre php_pcre.c /ext/pcre/tests bug42945.phpt

2008-01-13 Thread Nuno Lopes
nlopess Sun Jan 13 14:57:54 2008 UTC

  Modified files:  
/php-src/ext/pcre   php_pcre.c 
/php-src/ext/pcre/tests bug42945.phpt 
  Log:
  MFB: fix bug #42945
  
http://cvs.php.net/viewvc.cgi/php-src/ext/pcre/php_pcre.c?r1=1.227r2=1.228diff_format=u
Index: php-src/ext/pcre/php_pcre.c
diff -u php-src/ext/pcre/php_pcre.c:1.227 php-src/ext/pcre/php_pcre.c:1.228
--- php-src/ext/pcre/php_pcre.c:1.227   Mon Dec 31 07:12:12 2007
+++ php-src/ext/pcre/php_pcre.c Sun Jan 13 14:57:53 2008
@@ -16,7 +16,7 @@
+--+
  */
 
-/* $Id: php_pcre.c,v 1.227 2007/12/31 07:12:12 sebastian Exp $ */
+/* $Id: php_pcre.c,v 1.228 2008/01/13 14:57:53 nlopess Exp $ */
 
 /*  TODO
  *  php_pcre_replace_impl():
@@ -1747,7 +1747,9 @@
}
 
 
-   if (!no_empty || start_offset != subject_len)
+   start_offset = last_match - subject; /* the offset might have been 
incremented, but without further successful matches */
+
+   if (!no_empty || start_offset  subject_len)
{
if (offset_capture) {
/* Add the last (match, offset) pair to the return 
value */
http://cvs.php.net/viewvc.cgi/php-src/ext/pcre/tests/bug42945.phpt?r1=1.1r2=1.2diff_format=u
Index: php-src/ext/pcre/tests/bug42945.phpt
diff -u /dev/null php-src/ext/pcre/tests/bug42945.phpt:1.2
--- /dev/null   Sun Jan 13 14:57:54 2008
+++ php-src/ext/pcre/tests/bug42945.phptSun Jan 13 14:57:54 2008
@@ -0,0 +1,162 @@
+--TEST--
+Bug #42945 (preg_split() swallows part of the string)
+--FILE--
+?php
+
+var_dump(preg_match_all('/\b/', a', $m, PREG_OFFSET_CAPTURE));
+var_dump($m);
+
+var_dump(preg_split('/\b/', a'));
+var_dump(preg_split('/\b/', a', -1, PREG_SPLIT_OFFSET_CAPTURE));
+var_dump(preg_split('/\b/', a', -1, PREG_SPLIT_NO_EMPTY));
+var_dump(preg_split('/\b/', a', -1, 
PREG_SPLIT_NO_EMPTY|PREG_SPLIT_OFFSET_CAPTURE));
+
+?
+--EXPECT--
+int(2)
+array(1) {
+  [0]=
+  array(2) {
+[0]=
+array(2) {
+  [0]=
+  string(0) 
+  [1]=
+  int(0)
+}
+[1]=
+array(2) {
+  [0]=
+  string(0) 
+  [1]=
+  int(1)
+}
+  }
+}
+array(3) {
+  [0]=
+  string(0) 
+  [1]=
+  string(1) a
+  [2]=
+  string(1) '
+}
+array(3) {
+  [0]=
+  array(2) {
+[0]=
+string(0) 
+[1]=
+int(0)
+  }
+  [1]=
+  array(2) {
+[0]=
+string(1) a
+[1]=
+int(0)
+  }
+  [2]=
+  array(2) {
+[0]=
+string(1) '
+[1]=
+int(1)
+  }
+}
+array(2) {
+  [0]=
+  string(1) a
+  [1]=
+  string(1) '
+}
+array(2) {
+  [0]=
+  array(2) {
+[0]=
+string(1) a
+[1]=
+int(0)
+  }
+  [1]=
+  array(2) {
+[0]=
+string(1) '
+[1]=
+int(1)
+  }
+}
+--UEXPECT--
+int(2)
+array(1) {
+  [0]=
+  array(2) {
+[0]=
+array(2) {
+  [0]=
+  unicode(0) 
+  [1]=
+  int(0)
+}
+[1]=
+array(2) {
+  [0]=
+  unicode(0) 
+  [1]=
+  int(1)
+}
+  }
+}
+array(3) {
+  [0]=
+  unicode(0) 
+  [1]=
+  unicode(1) a
+  [2]=
+  unicode(1) '
+}
+array(3) {
+  [0]=
+  array(2) {
+[0]=
+unicode(0) 
+[1]=
+int(0)
+  }
+  [1]=
+  array(2) {
+[0]=
+unicode(1) a
+[1]=
+int(0)
+  }
+  [2]=
+  array(2) {
+[0]=
+unicode(1) '
+[1]=
+int(1)
+  }
+}
+array(2) {
+  [0]=
+  unicode(1) a
+  [1]=
+  unicode(1) '
+}
+array(2) {
+  [0]=
+  array(2) {
+[0]=
+unicode(1) a
+[1]=
+int(0)
+  }
+  [1]=
+  array(2) {
+[0]=
+unicode(1) '
+[1]=
+int(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_3) /ext/pcre upgrade-pcre.php

2008-01-14 Thread Nuno Lopes
nlopess Mon Jan 14 09:40:29 2008 UTC

  Modified files:  (Branch: PHP_5_3)
/php-src/ext/pcre   upgrade-pcre.php 
  Log:
  MFB5.2: fix script for files with short names
  
http://cvs.php.net/viewvc.cgi/php-src/ext/pcre/upgrade-pcre.php?r1=1.1.2.3r2=1.1.2.3.2.1diff_format=u
Index: php-src/ext/pcre/upgrade-pcre.php
diff -u php-src/ext/pcre/upgrade-pcre.php:1.1.2.3 
php-src/ext/pcre/upgrade-pcre.php:1.1.2.3.2.1
--- php-src/ext/pcre/upgrade-pcre.php:1.1.2.3   Tue Sep 11 16:17:33 2007
+++ php-src/ext/pcre/upgrade-pcre.php   Mon Jan 14 09:40:29 2008
@@ -37,9 +37,9 @@
 
if ($file[0] === '.' ||
$file === 'CVS' ||
-   substr_compare($file, '.lo', -3, 3) == 0 ||
-   substr_compare($file, '.loT', -4, 4) == 0 ||
-   substr_compare($file, '.o', -2, 2) == 0) continue;
+   @substr_compare($file, '.lo', -3, 3) === 0 ||
+   @substr_compare($file, '.loT', -4, 4) === 0 ||
+   @substr_compare($file, '.o', -2, 2) === 0) continue;
 
$file = $path/$file;
 

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



[PHP-CVS] cvs: php-src /ext/pcre upgrade-pcre.php

2008-01-14 Thread Nuno Lopes
nlopess Mon Jan 14 09:40:53 2008 UTC

  Modified files:  
/php-src/ext/pcre   upgrade-pcre.php 
  Log:
  MFB5.2: fix script for files with short names
  
http://cvs.php.net/viewvc.cgi/php-src/ext/pcre/upgrade-pcre.php?r1=1.2r2=1.3diff_format=u
Index: php-src/ext/pcre/upgrade-pcre.php
diff -u php-src/ext/pcre/upgrade-pcre.php:1.2 
php-src/ext/pcre/upgrade-pcre.php:1.3
--- php-src/ext/pcre/upgrade-pcre.php:1.2   Tue Sep 11 16:19:14 2007
+++ php-src/ext/pcre/upgrade-pcre.php   Mon Jan 14 09:40:53 2008
@@ -37,9 +37,9 @@
 
if ($file[0] === '.' ||
$file === 'CVS' ||
-   substr_compare($file, '.lo', -3, 3) == 0 ||
-   substr_compare($file, '.loT', -4, 4) == 0 ||
-   substr_compare($file, '.o', -2, 2) == 0) continue;
+   @substr_compare($file, '.lo', -3, 3) === 0 ||
+   @substr_compare($file, '.loT', -4, 4) === 0 ||
+   @substr_compare($file, '.o', -2, 2) === 0) continue;
 
$file = $path/$file;
 

-- 
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/dir .cvsignore

2008-01-14 Thread Nuno Lopes
nlopess Mon Jan 14 09:32:32 2008 UTC

  Modified files:  
/php-src/ext/standard/tests/dir .cvsignore 
  Log:
  add cvsignore
  
http://cvs.php.net/viewvc.cgi/php-src/ext/standard/tests/dir/.cvsignore?r1=1.1r2=1.2diff_format=u
Index: php-src/ext/standard/tests/dir/.cvsignore
diff -u /dev/null php-src/ext/standard/tests/dir/.cvsignore:1.2
--- /dev/null   Mon Jan 14 09:32:32 2008
+++ php-src/ext/standard/tests/dir/.cvsignore   Mon Jan 14 09:32:32 2008
@@ -0,0 +1,6 @@
+*.mem
+*.diff
+*.log
+*.exp
+*.out
+*.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_3) /ext/standard/tests/dir .cvsignore

2008-01-14 Thread Nuno Lopes
nlopess Mon Jan 14 09:31:56 2008 UTC

  Added files: (Branch: PHP_5_3)
/php-src/ext/standard/tests/dir .cvsignore 
  Log:
  ignore run-tests generated files
  

http://cvs.php.net/viewvc.cgi/php-src/ext/standard/tests/dir/.cvsignore?view=markuprev=1.1
Index: php-src/ext/standard/tests/dir/.cvsignore
+++ php-src/ext/standard/tests/dir/.cvsignore

-- 
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/pcre php_pcre.c /ext/pcre/tests bug42945.phpt

2008-01-14 Thread Nuno Lopes
nlopess Mon Jan 14 09:46:55 2008 UTC

  Added files: (Branch: PHP_5_2)
/php-src/ext/pcre/tests bug42945.phpt 

  Modified files:  
/php-srcNEWS 
/php-src/ext/pcre   php_pcre.c 
  Log:
  MFH: fix bug #42945, as asked by Ilia
  
http://cvs.php.net/viewvc.cgi/php-src/NEWS?r1=1.2027.2.547.2.1053r2=1.2027.2.547.2.1054diff_format=u
Index: php-src/NEWS
diff -u php-src/NEWS:1.2027.2.547.2.1053 php-src/NEWS:1.2027.2.547.2.1054
--- php-src/NEWS:1.2027.2.547.2.1053Mon Jan 14 09:39:40 2008
+++ php-src/NEWSMon Jan 14 09:46:54 2008
@@ -67,6 +67,7 @@
 - Fixed bug #43105 (PHP seems to fail to close open files). (Hannes)
 - Fixed bug #42978 (mismatch between number of bound params and values causes
   a crash in pdo_pgsql). (Ilia)
+- Fixed bug #42945 (preg_split() swallows part of the string). (Nuno)
 - Fixed bug #42937 (__call() method not invoked when methods are called on
   parent from child class). (Dmitry)
 - Fixed bug #42736 (xmlrpc_server_call_method() crashes). (Tony)
http://cvs.php.net/viewvc.cgi/php-src/ext/pcre/php_pcre.c?r1=1.168.2.9.2.23r2=1.168.2.9.2.24diff_format=u
Index: php-src/ext/pcre/php_pcre.c
diff -u php-src/ext/pcre/php_pcre.c:1.168.2.9.2.23 
php-src/ext/pcre/php_pcre.c:1.168.2.9.2.24
--- php-src/ext/pcre/php_pcre.c:1.168.2.9.2.23  Mon Dec 31 07:20:09 2007
+++ php-src/ext/pcre/php_pcre.c Mon Jan 14 09:46:54 2008
@@ -16,7 +16,7 @@
+--+
  */
 
-/* $Id: php_pcre.c,v 1.168.2.9.2.23 2007/12/31 07:20:09 sebastian Exp $ */
+/* $Id: php_pcre.c,v 1.168.2.9.2.24 2008/01/14 09:46:54 nlopess Exp $ */
 
 #include php.h
 #include php_ini.h
@@ -1535,7 +1535,9 @@
}
 
 
-   if (!no_empty || start_offset != subject_len)
+   start_offset = last_match - subject; /* the offset might have been 
incremented, but without further successful matches */
+
+   if (!no_empty || start_offset  subject_len)
{
if (offset_capture) {
/* Add the last (match, offset) pair to the return 
value */

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

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



[PHP-CVS] cvs: php-src /ext/zlib/tests ob_003.phpt ob_004.phpt ob_005.phpt

2008-01-14 Thread Nuno Lopes
nlopess Mon Jan 14 10:00:25 2008 UTC

  Modified files:  
/php-src/ext/zlib/tests ob_003.phpt ob_004.phpt ob_005.phpt 
  Log:
  force tests to be run in CGI mode
  
http://cvs.php.net/viewvc.cgi/php-src/ext/zlib/tests/ob_003.phpt?r1=1.2r2=1.3diff_format=u
Index: php-src/ext/zlib/tests/ob_003.phpt
diff -u php-src/ext/zlib/tests/ob_003.phpt:1.2 
php-src/ext/zlib/tests/ob_003.phpt:1.3
--- php-src/ext/zlib/tests/ob_003.phpt:1.2  Thu Aug 31 16:28:46 2006
+++ php-src/ext/zlib/tests/ob_003.phpt  Mon Jan 14 10:00:25 2008
@@ -9,6 +9,8 @@
 zlib.output_compression=0
 --ENV--
 HTTP_ACCEPT_ENCODING=gzip
+--POST--
+dummy=42
 --FILE--
 ?php
 ini_set(zlib.output_compression, 1);
http://cvs.php.net/viewvc.cgi/php-src/ext/zlib/tests/ob_004.phpt?r1=1.1r2=1.2diff_format=u
Index: php-src/ext/zlib/tests/ob_004.phpt
diff -u php-src/ext/zlib/tests/ob_004.phpt:1.1 
php-src/ext/zlib/tests/ob_004.phpt:1.2
--- php-src/ext/zlib/tests/ob_004.phpt:1.1  Mon Sep  4 10:31:11 2006
+++ php-src/ext/zlib/tests/ob_004.phpt  Mon Jan 14 10:00:25 2008
@@ -9,6 +9,8 @@
 zlib.output_compression=0
 --ENV--
 HTTP_ACCEPT_ENCODING=gzip
+--POST--
+dummy=42
 --FILE--
 ?php
 ob_start(ob_gzhandler);
http://cvs.php.net/viewvc.cgi/php-src/ext/zlib/tests/ob_005.phpt?r1=1.1r2=1.2diff_format=u
Index: php-src/ext/zlib/tests/ob_005.phpt
diff -u php-src/ext/zlib/tests/ob_005.phpt:1.1 
php-src/ext/zlib/tests/ob_005.phpt:1.2
--- php-src/ext/zlib/tests/ob_005.phpt:1.1  Mon Sep  4 10:31:11 2006
+++ php-src/ext/zlib/tests/ob_005.phpt  Mon Jan 14 10:00:25 2008
@@ -9,6 +9,8 @@
 zlib.output_compression=0
 --ENV--
 HTTP_ACCEPT_ENCODING=gzip
+--POST--
+dummy=42
 --FILE--
 ?php
 ob_start(ob_gzhandler);

-- 
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-01-17 Thread Nuno Lopes
nlopess Thu Jan 17 23:02:51 2008 UTC

  Modified files:  (Branch: PHP_5_3)
/php-srcNEWS 
  Log:
  pcre 7.5 is in 5.2 branch as well
  
http://cvs.php.net/viewvc.cgi/php-src/NEWS?r1=1.2027.2.547.2.965.2.77r2=1.2027.2.547.2.965.2.78diff_format=u
Index: php-src/NEWS
diff -u php-src/NEWS:1.2027.2.547.2.965.2.77 
php-src/NEWS:1.2027.2.547.2.965.2.78
--- php-src/NEWS:1.2027.2.547.2.965.2.77Thu Jan 17 20:59:10 2008
+++ php-src/NEWSThu Jan 17 23:02:50 2008
@@ -42,7 +42,6 @@
   invoking the date parser. (Scott)
 
 - Removed the experimental RPL (master/slave) functions from mysqli. (Andrey)
-- Upgraded PCRE to version 7.5 (Nuno)
 
 - Improved php.ini handling: (Jani)
   . Added .htaccess style user-defined php.ini files support for CGI/FastCGI

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



[PHP-CVS] cvs: php-src /ext/pdo pdo_sqlstate.c

2008-01-25 Thread Nuno Lopes
nlopess Fri Jan 25 19:58:51 2008 UTC

  Modified files:  
/php-src/ext/pdopdo_sqlstate.c 
  Log:
  MFB: move data to const segment
  
http://cvs.php.net/viewvc.cgi/php-src/ext/pdo/pdo_sqlstate.c?r1=1.11r2=1.12diff_format=u
Index: php-src/ext/pdo/pdo_sqlstate.c
diff -u php-src/ext/pdo/pdo_sqlstate.c:1.11 php-src/ext/pdo/pdo_sqlstate.c:1.12
--- php-src/ext/pdo/pdo_sqlstate.c:1.11 Mon Dec 31 07:12:13 2007
+++ php-src/ext/pdo/pdo_sqlstate.c  Fri Jan 25 19:58:51 2008
@@ -16,7 +16,7 @@
   +--+
 */
 
-/* $Id: pdo_sqlstate.c,v 1.11 2007/12/31 07:12:13 sebastian Exp $ */
+/* $Id: pdo_sqlstate.c,v 1.12 2008/01/25 19:58:51 nlopess Exp $ */
 
 #ifdef HAVE_CONFIG_H
 #include config.h
@@ -29,13 +29,13 @@
 #include php_pdo_driver.h
 
 struct pdo_sqlstate_info {
-   char state[6];
+   const char state[5];
const char *desc;
 };
 
 static HashTable err_hash;
 
-static struct pdo_sqlstate_info err_initializer[] = {
+static const struct pdo_sqlstate_info err_initializer[] = {
{ 0,  No error },
{ 01000,  Warning },
{ 01001,  Cursor operation conflict },
@@ -312,7 +312,7 @@
 int pdo_sqlstate_init_error_table(void)
 {
int i;
-   struct pdo_sqlstate_info *info;
+   const struct pdo_sqlstate_info *info;
 
if (FAILURE == zend_hash_init(err_hash,
sizeof(err_initializer)/sizeof(err_initializer[0]), 
NULL, NULL, 1)) {
@@ -330,7 +330,7 @@
 
 const char *pdo_sqlstate_state_to_description(char *state)
 {
-   struct pdo_sqlstate_info **info;
+   const struct pdo_sqlstate_info **info;
if (SUCCESS == zend_hash_find(err_hash, state, 
sizeof(err_initializer[0].state),
(void**)info)) {
return (*info)-desc;

-- 
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/ereg/regex cclass.h regerror.c

2008-01-25 Thread Nuno Lopes
nlopess Fri Jan 25 20:11:53 2008 UTC

  Modified files:  (Branch: PHP_5_3)
/php-src/ext/ereg/regex cclass.h regerror.c 
  Log:
  const'ify more 372 bytes
  
http://cvs.php.net/viewvc.cgi/php-src/ext/ereg/regex/cclass.h?r1=1.4.8.2r2=1.4.8.3diff_format=u
Index: php-src/ext/ereg/regex/cclass.h
diff -u php-src/ext/ereg/regex/cclass.h:1.4.8.2 
php-src/ext/ereg/regex/cclass.h:1.4.8.3
--- php-src/ext/ereg/regex/cclass.h:1.4.8.2 Fri Oct  5 15:00:06 2007
+++ php-src/ext/ereg/regex/cclass.h Fri Jan 25 20:11:53 2008
@@ -1,8 +1,8 @@
 /* character-class table */
-static struct cclass {
-   unsigned char *name;
-   unsigned char *chars;
-   unsigned char *multis;
+static const struct cclass {
+   const unsigned char *name;
+   const unsigned char *chars;
+   const unsigned char *multis;
 } cclasses[] = {
{alnum,   
ABCDEFGHIJKLMNOPQRSTUVWXYZabcdefghijklmnopqrstuvwxyz0123456789,   
},
{alpha,   ABCDEFGHIJKLMNOPQRSTUVWXYZabcdefghijklmnopqrstuvwxyz,
http://cvs.php.net/viewvc.cgi/php-src/ext/ereg/regex/regerror.c?r1=1.6.6.3r2=1.6.6.4diff_format=u
Index: php-src/ext/ereg/regex/regerror.c
diff -u php-src/ext/ereg/regex/regerror.c:1.6.6.3 
php-src/ext/ereg/regex/regerror.c:1.6.6.4
--- php-src/ext/ereg/regex/regerror.c:1.6.6.3   Thu Jan 24 23:02:07 2008
+++ php-src/ext/ereg/regex/regerror.c   Fri Jan 25 20:11:53 2008
@@ -30,10 +30,10 @@
  = #define REG_ATOI255 // convert name to number (!)
  = #define REG_ITOA0400// convert number to name (!)
  */
-static struct rerr {
+static const struct rerr {
int code;
-   char *name;
-   char *explain;
+   const char *name;
+   const char *explain;
 } rerrs[] = {
{REG_OKAY,  REG_OKAY, no errors detected},
{REG_NOMATCH,   REG_NOMATCH,  regexec() failed to match},
@@ -67,10 +67,10 @@
 char *errbuf,
 size_t errbuf_size)
 {
-   register struct rerr *r;
+   register const struct rerr *r;
register size_t len;
register int target = errcode ~ REG_ITOA;
-   register char *s;
+   register const char *s;
char convbuf[50];
 
if (errcode == REG_ATOI)
@@ -113,7 +113,7 @@
 const regex_t *preg;
 char *localbuf;
 {
-   register struct rerr *r;
+   register const struct rerr *r;
 
for (r = rerrs; r-code = 0; r++)
if (strcmp(r-name, preg-re_endp) == 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) /ext/spl php_spl.c php_spl.h /ext/tidy php_tidy.h tidy.c

2008-01-25 Thread Nuno Lopes
nlopess Fri Jan 25 20:29:48 2008 UTC

  Modified files:  (Branch: PHP_5_3)
/php-src/ext/splphp_spl.c php_spl.h 
/php-src/ext/tidy   php_tidy.h tidy.c 
  Log:
  more const kewywording
  remove spl_functions_none var (wast used anywhere
  
http://cvs.php.net/viewvc.cgi/php-src/ext/spl/php_spl.c?r1=1.52.2.28.2.17.2.7r2=1.52.2.28.2.17.2.8diff_format=u
Index: php-src/ext/spl/php_spl.c
diff -u php-src/ext/spl/php_spl.c:1.52.2.28.2.17.2.7 
php-src/ext/spl/php_spl.c:1.52.2.28.2.17.2.8
--- php-src/ext/spl/php_spl.c:1.52.2.28.2.17.2.7Tue Jan 15 09:38:15 2008
+++ php-src/ext/spl/php_spl.c   Fri Jan 25 20:29:48 2008
@@ -16,7 +16,7 @@
+--+
  */
 
-/* $Id: php_spl.c,v 1.52.2.28.2.17.2.7 2008/01/15 09:38:15 colder Exp $ */
+/* $Id: php_spl.c,v 1.52.2.28.2.17.2.8 2008/01/25 20:29:48 nlopess Exp $ */
 
 #ifdef HAVE_CONFIG_H
 #include config.h
@@ -48,13 +48,6 @@
 
 #define SPL_DEFAULT_FILE_EXTENSIONS .inc,.php
 
-/* {{{ spl_functions_none
- */
-const zend_function_entry spl_functions_none[] = {
-   {NULL, NULL, NULL}
-};
-/* }}} */
-
 /* {{{ PHP_GINIT_FUNCTION
  */
 static PHP_GINIT_FUNCTION(spl)
@@ -771,7 +764,7 @@
 
 /* {{{ spl_module_entry
  */
-zend_module_entry spl_module_entry = {
+const zend_module_entry spl_module_entry = {
 #ifdef HAVE_SIMPLEXML
STANDARD_MODULE_HEADER_EX, NULL,
spl_deps,
http://cvs.php.net/viewvc.cgi/php-src/ext/spl/php_spl.h?r1=1.17.2.1.2.3.2.2r2=1.17.2.1.2.3.2.3diff_format=u
Index: php-src/ext/spl/php_spl.h
diff -u php-src/ext/spl/php_spl.h:1.17.2.1.2.3.2.2 
php-src/ext/spl/php_spl.h:1.17.2.1.2.3.2.3
--- php-src/ext/spl/php_spl.h:1.17.2.1.2.3.2.2  Mon Dec 31 07:17:14 2007
+++ php-src/ext/spl/php_spl.h   Fri Jan 25 20:29:48 2008
@@ -28,7 +28,7 @@
 #define SPL_DEBUG(x)
 #endif
 
-extern zend_module_entry spl_module_entry;
+extern const zend_module_entry spl_module_entry;
 #define phpext_spl_ptr spl_module_entry
 
 #ifdef PHP_WIN32
http://cvs.php.net/viewvc.cgi/php-src/ext/tidy/php_tidy.h?r1=1.26.2.1.2.5.2.1r2=1.26.2.1.2.5.2.2diff_format=u
Index: php-src/ext/tidy/php_tidy.h
diff -u php-src/ext/tidy/php_tidy.h:1.26.2.1.2.5.2.1 
php-src/ext/tidy/php_tidy.h:1.26.2.1.2.5.2.2
--- php-src/ext/tidy/php_tidy.h:1.26.2.1.2.5.2.1Mon Dec 31 07:17:16 2007
+++ php-src/ext/tidy/php_tidy.h Fri Jan 25 20:29:48 2008
@@ -16,12 +16,12 @@
   +--+
 */
 
-/* $Id: php_tidy.h,v 1.26.2.1.2.5.2.1 2007/12/31 07:17:16 sebastian Exp $ */
+/* $Id: php_tidy.h,v 1.26.2.1.2.5.2.2 2008/01/25 20:29:48 nlopess Exp $ */
 
 #ifndef PHP_TIDY_H
 #define PHP_TIDY_H
 
-extern zend_module_entry tidy_module_entry;
+extern const zend_module_entry tidy_module_entry;
 #define phpext_tidy_ptr tidy_module_entry
 
 #define TIDY_METHOD_MAP(name, func_name, arg_types) \
http://cvs.php.net/viewvc.cgi/php-src/ext/tidy/tidy.c?r1=1.66.2.8.2.24.2.3r2=1.66.2.8.2.24.2.4diff_format=u
Index: php-src/ext/tidy/tidy.c
diff -u php-src/ext/tidy/tidy.c:1.66.2.8.2.24.2.3 
php-src/ext/tidy/tidy.c:1.66.2.8.2.24.2.4
--- php-src/ext/tidy/tidy.c:1.66.2.8.2.24.2.3   Mon Dec 31 07:17:16 2007
+++ php-src/ext/tidy/tidy.c Fri Jan 25 20:29:48 2008
@@ -16,7 +16,7 @@
   +--+
 */
 
-/* $Id: tidy.c,v 1.66.2.8.2.24.2.3 2007/12/31 07:17:16 sebastian Exp $ */
+/* $Id: tidy.c,v 1.66.2.8.2.24.2.4 2008/01/25 20:29:48 nlopess Exp $ */
 
 #ifdef HAVE_CONFIG_H
 #include config.h
@@ -351,7 +351,7 @@
 static zend_object_handlers tidy_object_handlers_doc;
 static zend_object_handlers tidy_object_handlers_node;
 
-zend_module_entry tidy_module_entry = {
+const zend_module_entry tidy_module_entry = {
STANDARD_MODULE_HEADER,
tidy,
tidy_functions,
@@ -998,7 +998,7 @@
php_info_print_table_start();
php_info_print_table_header(2, Tidy support, enabled);
php_info_print_table_row(2, libTidy Release, (char 
*)tidyReleaseDate());
-   php_info_print_table_row(2, Extension Version, 
PHP_TIDY_MODULE_VERSION  ($Id: tidy.c,v 1.66.2.8.2.24.2.3 2007/12/31 07:17:16 
sebastian Exp $));
+   php_info_print_table_row(2, Extension Version, 
PHP_TIDY_MODULE_VERSION  ($Id: tidy.c,v 1.66.2.8.2.24.2.4 2008/01/25 20:29:48 
nlopess Exp $));
php_info_print_table_end();
 
DISPLAY_INI_ENTRIES();

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

2008-01-25 Thread Nuno Lopes
nlopess Fri Jan 25 19:57:58 2008 UTC

  Modified files:  (Branch: PHP_5_3)
/php-src/ext/pdopdo_sqlstate.c 
  Log:
  move about 3K of data to the const area. also reduce memory usage (~ -266 
bytes :P)
  
http://cvs.php.net/viewvc.cgi/php-src/ext/pdo/pdo_sqlstate.c?r1=1.7.2.1.2.1.2.1r2=1.7.2.1.2.1.2.2diff_format=u
Index: php-src/ext/pdo/pdo_sqlstate.c
diff -u php-src/ext/pdo/pdo_sqlstate.c:1.7.2.1.2.1.2.1 
php-src/ext/pdo/pdo_sqlstate.c:1.7.2.1.2.1.2.2
--- php-src/ext/pdo/pdo_sqlstate.c:1.7.2.1.2.1.2.1  Mon Dec 31 07:17:11 2007
+++ php-src/ext/pdo/pdo_sqlstate.c  Fri Jan 25 19:57:57 2008
@@ -16,7 +16,7 @@
   +--+
 */
 
-/* $Id: pdo_sqlstate.c,v 1.7.2.1.2.1.2.1 2007/12/31 07:17:11 sebastian Exp $ */
+/* $Id: pdo_sqlstate.c,v 1.7.2.1.2.1.2.2 2008/01/25 19:57:57 nlopess Exp $ */
 
 #ifdef HAVE_CONFIG_H
 #include config.h
@@ -29,13 +29,13 @@
 #include php_pdo_driver.h
 
 struct pdo_sqlstate_info {
-   char state[6];
+   const char state[5];
const char *desc;
 };
 
 static HashTable err_hash;
 
-static struct pdo_sqlstate_info err_initializer[] = {
+static const struct pdo_sqlstate_info err_initializer[] = {
{ 0,  No error },
{ 01000,  Warning },
{ 01001,  Cursor operation conflict },
@@ -312,7 +312,7 @@
 int pdo_sqlstate_init_error_table(void)
 {
int i;
-   struct pdo_sqlstate_info *info;
+   const struct pdo_sqlstate_info *info;
 
if (FAILURE == zend_hash_init(err_hash,
sizeof(err_initializer)/sizeof(err_initializer[0]), 
NULL, NULL, 1)) {
@@ -330,7 +330,7 @@
 
 const char *pdo_sqlstate_state_to_description(char *state)
 {
-   struct pdo_sqlstate_info **info;
+   const struct pdo_sqlstate_info **info;
if (SUCCESS == zend_hash_find(err_hash, state, 
sizeof(err_initializer[0].state),
(void**)info)) {
return (*info)-desc;

-- 
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/ereg/regex cname.h

2008-01-25 Thread Nuno Lopes
nlopess Fri Jan 25 20:04:10 2008 UTC

  Modified files:  (Branch: PHP_5_3)
/php-src/ext/ereg/regex cname.h 
  Log:
  const'ify more 768 bytes
  
http://cvs.php.net/viewvc.cgi/php-src/ext/ereg/regex/cname.h?r1=1.3.36.2r2=1.3.36.3diff_format=u
Index: php-src/ext/ereg/regex/cname.h
diff -u php-src/ext/ereg/regex/cname.h:1.3.36.2 
php-src/ext/ereg/regex/cname.h:1.3.36.3
--- php-src/ext/ereg/regex/cname.h:1.3.36.2 Fri Oct  5 15:00:06 2007
+++ php-src/ext/ereg/regex/cname.h  Fri Jan 25 20:04:10 2008
@@ -1,6 +1,6 @@
 /* character-name table */
-static struct cname {
-   char *name;
+static const struct cname {
+   const char *name;
char code;
 } cnames[] = {
{NUL, '\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) /ext/pcre php_pcre.c php_pcre.h

2008-01-25 Thread Nuno Lopes
nlopess Fri Jan 25 19:38:26 2008 UTC

  Modified files:  (Branch: PHP_5_3)
/php-src/ext/pcre   php_pcre.c php_pcre.h 
  Log:
  spread some static keywords
  
http://cvs.php.net/viewvc.cgi/php-src/ext/pcre/php_pcre.c?r1=1.168.2.9.2.21.2.9r2=1.168.2.9.2.21.2.10diff_format=u
Index: php-src/ext/pcre/php_pcre.c
diff -u php-src/ext/pcre/php_pcre.c:1.168.2.9.2.21.2.9 
php-src/ext/pcre/php_pcre.c:1.168.2.9.2.21.2.10
--- php-src/ext/pcre/php_pcre.c:1.168.2.9.2.21.2.9  Sun Jan 13 14:44:29 2008
+++ php-src/ext/pcre/php_pcre.c Fri Jan 25 19:38:26 2008
@@ -16,7 +16,7 @@
+--+
  */
 
-/* $Id: php_pcre.c,v 1.168.2.9.2.21.2.9 2008/01/13 14:44:29 nlopess Exp $ */
+/* $Id: php_pcre.c,v 1.168.2.9.2.21.2.10 2008/01/25 19:38:26 nlopess Exp $ */
 
 #include php.h
 #include php_ini.h
@@ -748,7 +748,7 @@
 
 /* {{{ proto int preg_match(string pattern, string subject [, array 
subpatterns [, int flags [, int offset]]])
Perform a Perl-style regular expression match */
-PHP_FUNCTION(preg_match)
+static PHP_FUNCTION(preg_match)
 {
php_do_pcre_match(INTERNAL_FUNCTION_PARAM_PASSTHRU, 0);
 }
@@ -756,7 +756,7 @@
 
 /* {{{ proto int preg_match_all(string pattern, string subject, array 
subpatterns [, int flags [, int offset]])
Perform a Perl-style global regular expression match */
-PHP_FUNCTION(preg_match_all)
+static PHP_FUNCTION(preg_match_all)
 {
php_do_pcre_match(INTERNAL_FUNCTION_PARAM_PASSTHRU, 1);
 }
@@ -1369,7 +1369,7 @@
 
 /* {{{ proto string preg_replace(mixed regex, mixed replace, mixed subject [, 
int limit [, count]])
Perform Perl-style regular expression replacement. */
-PHP_FUNCTION(preg_replace)
+static PHP_FUNCTION(preg_replace)
 {
preg_replace_impl(INTERNAL_FUNCTION_PARAM_PASSTHRU, 0);
 }
@@ -1377,7 +1377,7 @@
 
 /* {{{ proto string preg_replace_callback(mixed regex, mixed callback, mixed 
subject [, int limit [, count]])
Perform Perl-style regular expression replacement using replacement 
callback. */
-PHP_FUNCTION(preg_replace_callback)
+static PHP_FUNCTION(preg_replace_callback)
 {
preg_replace_impl(INTERNAL_FUNCTION_PARAM_PASSTHRU, 1);
 }
@@ -1385,7 +1385,7 @@
 
 /* {{{ proto array preg_split(string pattern, string subject [, int limit [, 
int flags]]) 
Split string into an array using a perl-style regular expression as a 
delimiter */
-PHP_FUNCTION(preg_split)
+static PHP_FUNCTION(preg_split)
 {
char*regex; /* Regular 
expression */
char*subject;   /* String to 
match against */
@@ -1583,7 +1583,7 @@
 
 /* {{{ proto string preg_quote(string str [, string delim_char])
Quote regular expression characters plus an optional character */
-PHP_FUNCTION(preg_quote)
+static PHP_FUNCTION(preg_quote)
 {
int  in_str_len;
char*in_str;/* Input string argument */
@@ -1669,7 +1669,7 @@
 
 /* {{{ proto array preg_grep(string regex, array input [, int flags])
Searches array and returns entries which match regex */
-PHP_FUNCTION(preg_grep)
+static PHP_FUNCTION(preg_grep)
 {
char*regex; /* Regular 
expression */
int  regex_len;
@@ -1779,7 +1779,7 @@
 
 /* {{{ proto int preg_last_error()
Returns the error code of the last regexp execution. */
-PHP_FUNCTION(preg_last_error)
+static PHP_FUNCTION(preg_last_error)
 {
if (zend_parse_parameters(ZEND_NUM_ARGS() TSRMLS_CC, ) == FAILURE) {
return;
@@ -1791,7 +1791,7 @@
 
 /* {{{ module definition structures */
 
-const zend_function_entry pcre_functions[] = {
+static const zend_function_entry pcre_functions[] = {
PHP_FE(preg_match,  third_arg_force_ref)
PHP_FE(preg_match_all,  third_arg_force_ref)
PHP_FE(preg_replace,fifth_arg_force_ref)
http://cvs.php.net/viewvc.cgi/php-src/ext/pcre/php_pcre.h?r1=1.41.2.1.2.5.2.1r2=1.41.2.1.2.5.2.2diff_format=u
Index: php-src/ext/pcre/php_pcre.h
diff -u php-src/ext/pcre/php_pcre.h:1.41.2.1.2.5.2.1 
php-src/ext/pcre/php_pcre.h:1.41.2.1.2.5.2.2
--- php-src/ext/pcre/php_pcre.h:1.41.2.1.2.5.2.1Mon Dec 31 07:17:11 2007
+++ php-src/ext/pcre/php_pcre.h Fri Jan 25 19:38:26 2008
@@ -16,7 +16,7 @@
+--+
  */
  
-/* $Id: php_pcre.h,v 1.41.2.1.2.5.2.1 2007/12/31 07:17:11 sebastian Exp $ */
+/* $Id: php_pcre.h,v 1.41.2.1.2.5.2.2 2008/01/25 19:38:26 nlopess Exp $ */
 
 #ifndef PHP_PCRE_H
 #define PHP_PCRE_H
@@ -33,14 +33,6 @@
 #include locale.h
 #endif
 
-PHP_FUNCTION(preg_match);
-PHP_FUNCTION(preg_match_all);
-PHP_FUNCTION(preg_replace);
-PHP_FUNCTION(preg_replace_callback);
-PHP_FUNCTION(preg_split);
-PHP_FUNCTION(preg_quote);
-PHP_FUNCTION(preg_grep);
-
 PHPAPI char 

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

2008-01-25 Thread Nuno Lopes
nlopess Fri Jan 25 20:21:18 2008 UTC

  Modified files:  
/php-src/ext/filter filter.c 
  Log:
  MFB: const keywording
  
http://cvs.php.net/viewvc.cgi/php-src/ext/filter/filter.c?r1=1.89r2=1.90diff_format=u
Index: php-src/ext/filter/filter.c
diff -u php-src/ext/filter/filter.c:1.89 php-src/ext/filter/filter.c:1.90
--- php-src/ext/filter/filter.c:1.89Mon Dec 31 07:12:09 2007
+++ php-src/ext/filter/filter.c Fri Jan 25 20:21:18 2008
@@ -19,7 +19,7 @@
   +--+
 */
 
-/* $Id: filter.c,v 1.89 2007/12/31 07:12:09 sebastian Exp $ */
+/* $Id: filter.c,v 1.90 2008/01/25 20:21:18 nlopess Exp $ */
 
 #ifdef HAVE_CONFIG_H
 #include config.h
@@ -38,7 +38,7 @@
 } filter_list_entry;
 
 /* {{{ filter_list */
-filter_list_entry filter_list[] = {
+static const filter_list_entry filter_list[] = {
{ int, FILTER_VALIDATE_INT,   php_filter_int  
   },
{ boolean, FILTER_VALIDATE_BOOLEAN,   php_filter_boolean  
   },
{ float,   FILTER_VALIDATE_FLOAT, php_filter_float
   },
@@ -79,7 +79,7 @@
 
 /* {{{ filter_functions[]
  */
-const zend_function_entry filter_functions[] = {
+static const zend_function_entry filter_functions[] = {
PHP_FE(filter_input,NULL)
PHP_FE(filter_var,  NULL)
PHP_FE(filter_input_array,  NULL)
@@ -275,7 +275,7 @@
 {
php_info_print_table_start();
php_info_print_table_row( 2, Input Validation and Filtering, 
enabled );
-   php_info_print_table_row( 2, Revision, $Revision: 1.89 $);
+   php_info_print_table_row( 2, Revision, $Revision: 1.90 $);
php_info_print_table_end();
 
DISPLAY_INI_ENTRIES();

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



[PHP-CVS] cvs: php-src /ext/spl php_spl.c php_spl.h /ext/tidy php_tidy.h tidy.c

2008-01-25 Thread Nuno Lopes
nlopess Fri Jan 25 20:30:36 2008 UTC

  Modified files:  
/php-src/ext/splphp_spl.c php_spl.h 
/php-src/ext/tidy   php_tidy.h tidy.c 
  Log:
  MFB: const keywording
  
http://cvs.php.net/viewvc.cgi/php-src/ext/spl/php_spl.c?r1=1.120r2=1.121diff_format=u
Index: php-src/ext/spl/php_spl.c
diff -u php-src/ext/spl/php_spl.c:1.120 php-src/ext/spl/php_spl.c:1.121
--- php-src/ext/spl/php_spl.c:1.120 Tue Jan 15 09:37:50 2008
+++ php-src/ext/spl/php_spl.c   Fri Jan 25 20:30:36 2008
@@ -16,7 +16,7 @@
+--+
  */
 
-/* $Id: php_spl.c,v 1.120 2008/01/15 09:37:50 colder Exp $ */
+/* $Id: php_spl.c,v 1.121 2008/01/25 20:30:36 nlopess Exp $ */
 
 #ifdef HAVE_CONFIG_H
 #include config.h
@@ -46,13 +46,6 @@
 
 ZEND_DECLARE_MODULE_GLOBALS(spl)
 
-/* {{{ spl_functions_none
- */
-const zend_function_entry spl_functions_none[] = {
-   {NULL, NULL, NULL}
-};
-/* }}} */
-
 /* {{{ PHP_GINIT_FUNCTION
  */
 static PHP_GINIT_FUNCTION(spl)
@@ -788,7 +781,7 @@
 
 /* {{{ spl_module_entry
  */
-zend_module_entry spl_module_entry = {
+const zend_module_entry spl_module_entry = {
 #ifdef HAVE_SIMPLEXML
STANDARD_MODULE_HEADER_EX, NULL,
spl_deps,
http://cvs.php.net/viewvc.cgi/php-src/ext/spl/php_spl.h?r1=1.24r2=1.25diff_format=u
Index: php-src/ext/spl/php_spl.h
diff -u php-src/ext/spl/php_spl.h:1.24 php-src/ext/spl/php_spl.h:1.25
--- php-src/ext/spl/php_spl.h:1.24  Mon Dec 31 07:12:14 2007
+++ php-src/ext/spl/php_spl.h   Fri Jan 25 20:30:36 2008
@@ -28,7 +28,7 @@
 #define SPL_DEBUG(x)
 #endif
 
-extern zend_module_entry spl_module_entry;
+extern const zend_module_entry spl_module_entry;
 #define phpext_spl_ptr spl_module_entry
 
 #ifdef PHP_WIN32
http://cvs.php.net/viewvc.cgi/php-src/ext/tidy/php_tidy.h?r1=1.36r2=1.37diff_format=u
Index: php-src/ext/tidy/php_tidy.h
diff -u php-src/ext/tidy/php_tidy.h:1.36 php-src/ext/tidy/php_tidy.h:1.37
--- php-src/ext/tidy/php_tidy.h:1.36Mon Dec 31 07:12:17 2007
+++ php-src/ext/tidy/php_tidy.h Fri Jan 25 20:30:36 2008
@@ -16,12 +16,12 @@
   +--+
 */
 
-/* $Id: php_tidy.h,v 1.36 2007/12/31 07:12:17 sebastian Exp $ */
+/* $Id: php_tidy.h,v 1.37 2008/01/25 20:30:36 nlopess Exp $ */
 
 #ifndef PHP_TIDY_H
 #define PHP_TIDY_H
 
-extern zend_module_entry tidy_module_entry;
+extern const zend_module_entry tidy_module_entry;
 #define phpext_tidy_ptr tidy_module_entry
 
 #define TIDY_METHOD_MAP(name, func_name, arg_types) \
http://cvs.php.net/viewvc.cgi/php-src/ext/tidy/tidy.c?r1=1.118r2=1.119diff_format=u
Index: php-src/ext/tidy/tidy.c
diff -u php-src/ext/tidy/tidy.c:1.118 php-src/ext/tidy/tidy.c:1.119
--- php-src/ext/tidy/tidy.c:1.118   Mon Dec 31 07:12:17 2007
+++ php-src/ext/tidy/tidy.c Fri Jan 25 20:30:36 2008
@@ -16,7 +16,7 @@
   +--+
 */
 
-/* $Id: tidy.c,v 1.118 2007/12/31 07:12:17 sebastian Exp $ */
+/* $Id: tidy.c,v 1.119 2008/01/25 20:30:36 nlopess Exp $ */
 
 #ifdef HAVE_CONFIG_H
 #include config.h
@@ -359,7 +359,7 @@
 static zend_object_handlers tidy_object_handlers_doc;
 static zend_object_handlers tidy_object_handlers_node;
 
-zend_module_entry tidy_module_entry = {
+const zend_module_entry tidy_module_entry = {
STANDARD_MODULE_HEADER,
tidy,
tidy_functions,
@@ -1062,7 +1062,7 @@
php_info_print_table_start();
php_info_print_table_header(2, Tidy support, enabled);
php_info_print_table_row(2, libTidy Release, (char 
*)tidyReleaseDate());
-   php_info_print_table_row(2, Extension Version, 
PHP_TIDY_MODULE_VERSION  ($Id: tidy.c,v 1.118 2007/12/31 07:12:17 sebastian 
Exp $));
+   php_info_print_table_row(2, Extension Version, 
PHP_TIDY_MODULE_VERSION  ($Id: tidy.c,v 1.119 2008/01/25 20:30:36 nlopess Exp 
$));
php_info_print_table_end();
 
DISPLAY_INI_ENTRIES();

-- 
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/filter filter.c

2008-01-25 Thread Nuno Lopes
nlopess Fri Jan 25 20:20:07 2008 UTC

  Modified files:  (Branch: PHP_5_3)
/php-src/ext/filter filter.c 
  Log:
  const more 216 bytes (on a 32-bits host)
  
http://cvs.php.net/viewvc.cgi/php-src/ext/filter/filter.c?r1=1.52.2.39.2.2r2=1.52.2.39.2.3diff_format=u
Index: php-src/ext/filter/filter.c
diff -u php-src/ext/filter/filter.c:1.52.2.39.2.2 
php-src/ext/filter/filter.c:1.52.2.39.2.3
--- php-src/ext/filter/filter.c:1.52.2.39.2.2   Mon Dec 31 07:17:08 2007
+++ php-src/ext/filter/filter.c Fri Jan 25 20:20:07 2008
@@ -19,7 +19,7 @@
   +--+
 */
 
-/* $Id: filter.c,v 1.52.2.39.2.2 2007/12/31 07:17:08 sebastian Exp $ */
+/* $Id: filter.c,v 1.52.2.39.2.3 2008/01/25 20:20:07 nlopess Exp $ */
 
 #ifdef HAVE_CONFIG_H
 #include config.h
@@ -38,7 +38,7 @@
 } filter_list_entry;
 
 /* {{{ filter_list */
-filter_list_entry filter_list[] = {
+static const filter_list_entry filter_list[] = {
{ int, FILTER_VALIDATE_INT,   php_filter_int  
   },
{ boolean, FILTER_VALIDATE_BOOLEAN,   php_filter_boolean  
   },
{ float,   FILTER_VALIDATE_FLOAT, php_filter_float
   },
@@ -79,7 +79,7 @@
 
 /* {{{ filter_functions[]
  */
-const zend_function_entry filter_functions[] = {
+static const zend_function_entry filter_functions[] = {
PHP_FE(filter_input,NULL)
PHP_FE(filter_var,  NULL)
PHP_FE(filter_input_array,  NULL)
@@ -275,7 +275,7 @@
 {
php_info_print_table_start();
php_info_print_table_row( 2, Input Validation and Filtering, 
enabled );
-   php_info_print_table_row( 2, Revision, $Revision: 1.52.2.39.2.2 $);
+   php_info_print_table_row( 2, Revision, $Revision: 1.52.2.39.2.3 $);
php_info_print_table_end();
 
DISPLAY_INI_ENTRIES();

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



[PHP-CVS] cvs: php-src /ext/ereg/regex cname.h

2008-01-25 Thread Nuno Lopes
nlopess Fri Jan 25 20:04:44 2008 UTC

  Modified files:  
/php-src/ext/ereg/regex cname.h 
  Log:
  MFB: const'ify
  
http://cvs.php.net/viewvc.cgi/php-src/ext/ereg/regex/cname.h?r1=1.3r2=1.4diff_format=u
Index: php-src/ext/ereg/regex/cname.h
diff -u php-src/ext/ereg/regex/cname.h:1.3 php-src/ext/ereg/regex/cname.h:1.4
--- php-src/ext/ereg/regex/cname.h:1.3  Tue Dec 28 20:50:34 1999
+++ php-src/ext/ereg/regex/cname.h  Fri Jan 25 20:04:44 2008
@@ -1,6 +1,6 @@
 /* character-name table */
-static struct cname {
-   char *name;
+static const struct cname {
+   const char *name;
char code;
 } cnames[] = {
{NUL, '\0'},

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



[PHP-CVS] cvs: php-src /ext/pcre php_pcre.c php_pcre.h

2008-01-25 Thread Nuno Lopes
nlopess Fri Jan 25 19:39:45 2008 UTC

  Modified files:  
/php-src/ext/pcre   php_pcre.c php_pcre.h 
  Log:
  spread some static keywords
  
http://cvs.php.net/viewvc.cgi/php-src/ext/pcre/php_pcre.c?r1=1.228r2=1.229diff_format=u
Index: php-src/ext/pcre/php_pcre.c
diff -u php-src/ext/pcre/php_pcre.c:1.228 php-src/ext/pcre/php_pcre.c:1.229
--- php-src/ext/pcre/php_pcre.c:1.228   Sun Jan 13 14:57:53 2008
+++ php-src/ext/pcre/php_pcre.c Fri Jan 25 19:39:45 2008
@@ -16,7 +16,7 @@
+--+
  */
 
-/* $Id: php_pcre.c,v 1.228 2008/01/13 14:57:53 nlopess Exp $ */
+/* $Id: php_pcre.c,v 1.229 2008/01/25 19:39:45 nlopess Exp $ */
 
 /*  TODO
  *  php_pcre_replace_impl():
@@ -875,7 +875,7 @@
 
 /* {{{ proto int preg_match(string pattern, string subject [, array 
subpatterns [, int flags [, int offset]]]) U
Perform a Perl-style regular expression match */
-PHP_FUNCTION(preg_match)
+static PHP_FUNCTION(preg_match)
 {
php_do_pcre_match(INTERNAL_FUNCTION_PARAM_PASSTHRU, 0);
 }
@@ -883,7 +883,7 @@
 
 /* {{{ proto int preg_match_all(string pattern, string subject, array 
subpatterns [, int flags [, int offset]]) U
Perform a Perl-style global regular expression match */
-PHP_FUNCTION(preg_match_all)
+static PHP_FUNCTION(preg_match_all)
 {
php_do_pcre_match(INTERNAL_FUNCTION_PARAM_PASSTHRU, 1);
 }
@@ -1535,7 +1535,7 @@
 
 /* {{{ proto string preg_replace(mixed regex, mixed replace, mixed subject [, 
int limit [, count]]) U
Perform Perl-style regular expression replacement. */
-PHP_FUNCTION(preg_replace)
+static PHP_FUNCTION(preg_replace)
 {
preg_replace_impl(INTERNAL_FUNCTION_PARAM_PASSTHRU, 0);
 }
@@ -1543,7 +1543,7 @@
 
 /* {{{ proto string preg_replace_callback(mixed regex, mixed callback, mixed 
subject [, int limit [, count]]) U
Perform Perl-style regular expression replacement using replacement 
callback. */
-PHP_FUNCTION(preg_replace_callback)
+static PHP_FUNCTION(preg_replace_callback)
 {
preg_replace_impl(INTERNAL_FUNCTION_PARAM_PASSTHRU, 1);
 }
@@ -1551,7 +1551,7 @@
 
 /* {{{ proto array preg_split(string pattern, string subject [, int limit [, 
int flags]]) U
Split string into an array using a perl-style regular expression as a 
delimiter */
-PHP_FUNCTION(preg_split)
+static PHP_FUNCTION(preg_split)
 {
zstr regex; /* Regular 
expression */
zstr subject;   /* String to 
match against */
@@ -1771,7 +1771,7 @@
 
 /* {{{ proto string preg_quote(string str [, string delim_char]) U
Quote regular expression characters plus an optional character */
-PHP_FUNCTION(preg_quote)
+static PHP_FUNCTION(preg_quote)
 {
int  in_str_len;
char*in_str;/* Input string argument */
@@ -1876,7 +1876,7 @@
 
 /* {{{ proto array preg_grep(string regex, array input [, int flags]) U
Searches array and returns entries which match regex */
-PHP_FUNCTION(preg_grep)
+static PHP_FUNCTION(preg_grep)
 {
zstr regex; /* Regular 
expression */
int  regex_len;
@@ -2021,7 +2021,7 @@
 
 /* {{{ proto int preg_last_error()
Returns the error code of the last regexp execution. */
-PHP_FUNCTION(preg_last_error)
+static PHP_FUNCTION(preg_last_error)
 {
if (zend_parse_parameters(ZEND_NUM_ARGS() TSRMLS_CC, ) == FAILURE) {
return;
@@ -2033,7 +2033,7 @@
 
 /* {{{ module definition structures */
 
-const zend_function_entry pcre_functions[] = {
+static const zend_function_entry pcre_functions[] = {
PHP_FE(preg_match,  third_arg_force_ref)
PHP_FE(preg_match_all,  third_arg_force_ref)
PHP_FE(preg_replace,fifth_arg_force_ref)
http://cvs.php.net/viewvc.cgi/php-src/ext/pcre/php_pcre.h?r1=1.54r2=1.55diff_format=u
Index: php-src/ext/pcre/php_pcre.h
diff -u php-src/ext/pcre/php_pcre.h:1.54 php-src/ext/pcre/php_pcre.h:1.55
--- php-src/ext/pcre/php_pcre.h:1.54Mon Dec 31 07:12:12 2007
+++ php-src/ext/pcre/php_pcre.h Fri Jan 25 19:39:45 2008
@@ -16,7 +16,7 @@
+--+
  */
  
-/* $Id: php_pcre.h,v 1.54 2007/12/31 07:12:12 sebastian Exp $ */
+/* $Id: php_pcre.h,v 1.55 2008/01/25 19:39:45 nlopess Exp $ */
 
 #ifndef PHP_PCRE_H
 #define PHP_PCRE_H
@@ -33,14 +33,6 @@
 #include locale.h
 #endif
 
-PHP_FUNCTION(preg_match);
-PHP_FUNCTION(preg_match_all);
-PHP_FUNCTION(preg_replace);
-PHP_FUNCTION(preg_replace_callback);
-PHP_FUNCTION(preg_split);
-PHP_FUNCTION(preg_quote);
-PHP_FUNCTION(preg_grep);
-
 PHPAPI char *php_pcre_replace(zend_uchar utype, char *regex, int regex_len, 
char *subject, int subject_len, zval *replace_val, int is_callable_replace, int 
*result_len, int limit, int *replace_count TSRMLS_DC);
 

[PHP-CVS] cvs: php-src /ext/ereg/regex cclass.h regerror.c

2008-01-25 Thread Nuno Lopes
nlopess Fri Jan 25 20:20:54 2008 UTC

  Modified files:  
/php-src/ext/ereg/regex cclass.h regerror.c 
  Log:
  MFB: const keywording
  
http://cvs.php.net/viewvc.cgi/php-src/ext/ereg/regex/cclass.h?r1=1.4r2=1.5diff_format=u
Index: php-src/ext/ereg/regex/cclass.h
diff -u php-src/ext/ereg/regex/cclass.h:1.4 php-src/ext/ereg/regex/cclass.h:1.5
--- php-src/ext/ereg/regex/cclass.h:1.4 Tue Sep 30 00:26:03 2003
+++ php-src/ext/ereg/regex/cclass.h Fri Jan 25 20:20:54 2008
@@ -1,8 +1,8 @@
 /* character-class table */
-static struct cclass {
-   unsigned char *name;
-   unsigned char *chars;
-   unsigned char *multis;
+static const struct cclass {
+   const unsigned char *name;
+   const unsigned char *chars;
+   const unsigned char *multis;
 } cclasses[] = {
{alnum,   
ABCDEFGHIJKLMNOPQRSTUVWXYZabcdefghijklmnopqrstuvwxyz0123456789,   
},
{alpha,   ABCDEFGHIJKLMNOPQRSTUVWXYZabcdefghijklmnopqrstuvwxyz,
http://cvs.php.net/viewvc.cgi/php-src/ext/ereg/regex/regerror.c?r1=1.7r2=1.8diff_format=u
Index: php-src/ext/ereg/regex/regerror.c
diff -u php-src/ext/ereg/regex/regerror.c:1.7 
php-src/ext/ereg/regex/regerror.c:1.8
--- php-src/ext/ereg/regex/regerror.c:1.7   Thu Jan 24 23:01:47 2008
+++ php-src/ext/ereg/regex/regerror.c   Fri Jan 25 20:20:54 2008
@@ -30,10 +30,10 @@
  = #define REG_ATOI255 // convert name to number (!)
  = #define REG_ITOA0400// convert number to name (!)
  */
-static struct rerr {
+static const struct rerr {
int code;
-   char *name;
-   char *explain;
+   const char *name;
+   const char *explain;
 } rerrs[] = {
{REG_OKAY,  REG_OKAY, no errors detected},
{REG_NOMATCH,   REG_NOMATCH,  regexec() failed to match},
@@ -67,10 +67,10 @@
 char *errbuf,
 size_t errbuf_size)
 {
-   register struct rerr *r;
+   register const struct rerr *r;
register size_t len;
register int target = errcode ~ REG_ITOA;
-   register char *s;
+   register const char *s;
char convbuf[50];
 
if (errcode == REG_ATOI)
@@ -113,7 +113,7 @@
 const regex_t *preg;
 char *localbuf;
 {
-   register struct rerr *r;
+   register const struct rerr *r;
 
for (r = rerrs; r-code = 0; r++)
if (strcmp(r-name, preg-re_endp) == 0)

-- 
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/spl php_spl.c php_spl.h /ext/tidy php_tidy.h tidy.c

2008-01-26 Thread Nuno Lopes

On 25.01.2008 23:29, Nuno Lopes wrote:

-zend_module_entry spl_module_entry = {
+const zend_module_entry spl_module_entry = {



-zend_module_entry tidy_module_entry = {
+const zend_module_entry tidy_module_entry = {


This makes PHP to crash right after the start.
Please revert.


Ah damn.. Sorry for the breakage and thanks for letting me know about this.
(I though I had tested everything...) Tomorrow I'll fix it (today I'm just 
too tired).


Thanks,
Nuno 


--
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/strings moneyformat.phpt setlocale_basic1.phpt setlocale_basic2.phpt setlocale_basic3.phpt setlocale_variation1.phpt setlocale_variation3.phpt setlo

2008-01-27 Thread Nuno Lopes
nlopess Sun Jan 27 16:45:43 2008 UTC

  Modified files:  (Branch: PHP_5_3)
/php-src/ext/standard/tests/strings moneyformat.phpt 
setlocale_basic1.phpt 
setlocale_basic2.phpt 
setlocale_basic3.phpt 
setlocale_variation1.phpt 
setlocale_variation3.phpt 
setlocale_variation4.phpt 
setlocale_variation5.phpt 
  Log:
  fix a bunch of SKIPIF (check for non available locales)
  
http://cvs.php.net/viewvc.cgi/php-src/ext/standard/tests/strings/moneyformat.phpt?r1=1.1.2.2r2=1.1.2.2.2.1diff_format=u
Index: php-src/ext/standard/tests/strings/moneyformat.phpt
diff -u php-src/ext/standard/tests/strings/moneyformat.phpt:1.1.2.2 
php-src/ext/standard/tests/strings/moneyformat.phpt:1.1.2.2.2.1
--- php-src/ext/standard/tests/strings/moneyformat.phpt:1.1.2.2 Wed Jun  6 
17:46:17 2007
+++ php-src/ext/standard/tests/strings/moneyformat.phpt Sun Jan 27 16:45:43 2008
@@ -5,6 +5,10 @@
if (!function_exists('money_format') || !function_exists('setlocale')) {
die(SKIP money_format - not supported\n);
}
+
+if (setlocale(LC_MONETARY, 'en_US') == false) {
+   die('skip en_US locale not available');
+}
 ?
 --FILE--
 ?php
http://cvs.php.net/viewvc.cgi/php-src/ext/standard/tests/strings/setlocale_basic1.phpt?r1=1.1.4.3r2=1.1.4.4diff_format=u
Index: php-src/ext/standard/tests/strings/setlocale_basic1.phpt
diff -u php-src/ext/standard/tests/strings/setlocale_basic1.phpt:1.1.4.3 
php-src/ext/standard/tests/strings/setlocale_basic1.phpt:1.1.4.4
--- php-src/ext/standard/tests/strings/setlocale_basic1.phpt:1.1.4.3Wed Dec 
19 10:39:10 2007
+++ php-src/ext/standard/tests/strings/setlocale_basic1.phptSun Jan 27 
16:45:43 2008
@@ -5,6 +5,9 @@
 if (substr(PHP_OS, 0, 3) == 'WIN') {
 die('skip Not valid for windows');
 }
+if (setlocale(LC_ALL, en_US.utf8, en_AU.utf8, ko_KR.utf8, zh_CN.utf8, 
de_DE.utf8, es_EC.utf8, fr_FR.utf8, ja_JP.utf8, el_GR.utf8, 
nl_NL.utf8) === false) {
+die('skip available locales not usable');
+}
 ?
 --FILE--
 ?php
http://cvs.php.net/viewvc.cgi/php-src/ext/standard/tests/strings/setlocale_basic2.phpt?r1=1.1.4.2r2=1.1.4.3diff_format=u
Index: php-src/ext/standard/tests/strings/setlocale_basic2.phpt
diff -u php-src/ext/standard/tests/strings/setlocale_basic2.phpt:1.1.4.2 
php-src/ext/standard/tests/strings/setlocale_basic2.phpt:1.1.4.3
--- php-src/ext/standard/tests/strings/setlocale_basic2.phpt:1.1.4.2Fri Oct 
 5 19:32:28 2007
+++ php-src/ext/standard/tests/strings/setlocale_basic2.phptSun Jan 27 
16:45:43 2008
@@ -5,6 +5,9 @@
 if (substr(PHP_OS, 0, 3) == 'WIN') {
 die('skip Not valid for windows');
 }
+if (setlocale(LC_ALL, en_US.utf8, en_AU.utf8, ko_KR.utf8, zh_CN.utf8, 
de_DE.utf8, es_EC.utf8, fr_FR.utf8, ja_JP.utf8, el_GR.utf8, 
nl_NL.utf8) === false) {
+die('skip available locales not usable');
+}
 ?
 --FILE--
 ?php
http://cvs.php.net/viewvc.cgi/php-src/ext/standard/tests/strings/setlocale_basic3.phpt?r1=1.1.4.2r2=1.1.4.3diff_format=u
Index: php-src/ext/standard/tests/strings/setlocale_basic3.phpt
diff -u php-src/ext/standard/tests/strings/setlocale_basic3.phpt:1.1.4.2 
php-src/ext/standard/tests/strings/setlocale_basic3.phpt:1.1.4.3
--- php-src/ext/standard/tests/strings/setlocale_basic3.phpt:1.1.4.2Fri Oct 
 5 19:32:28 2007
+++ php-src/ext/standard/tests/strings/setlocale_basic3.phptSun Jan 27 
16:45:43 2008
@@ -5,6 +5,9 @@
 if (substr(PHP_OS, 0, 3) == 'WIN') {
 die('skip Not valid for windows');
 }
+if (setlocale(LC_ALL, en_US.utf8, Ko_KR.utf8, zh_CN.utf8) === false) {
+die('skip en_US.utf8/Ko_KR.utf8/zh_CN.utf8 locales not available');
+}
 ?
 --FILE--
 ?php
http://cvs.php.net/viewvc.cgi/php-src/ext/standard/tests/strings/setlocale_variation1.phpt?r1=1.1.4.2r2=1.1.4.3diff_format=u
Index: php-src/ext/standard/tests/strings/setlocale_variation1.phpt
diff -u php-src/ext/standard/tests/strings/setlocale_variation1.phpt:1.1.4.2 
php-src/ext/standard/tests/strings/setlocale_variation1.phpt:1.1.4.3
--- php-src/ext/standard/tests/strings/setlocale_variation1.phpt:1.1.4.2
Fri Oct  5 19:32:28 2007
+++ php-src/ext/standard/tests/strings/setlocale_variation1.phptSun Jan 
27 16:45:43 2008
@@ -5,6 +5,9 @@
 if (substr(PHP_OS, 0, 3) == 'WIN') {
 die('skip Not valid for windows');
 }
+if (setlocale(LC_ALL, en_US.utf8, Ko_KR.utf8, zh_CN.utf8) === false) {
+die('skip en_US.utf8/Ko_KR.utf8/zh_CN.utf8 locales not available');
+}
 ?
 --FILE--
 ?php
http://cvs.php.net/viewvc.cgi/php-src/ext/standard/tests/strings/setlocale_variation3.phpt?r1=1.1.4.2r2=1.1.4.3diff_format=u
Index: php-src/ext/standard/tests/strings/setlocale_variation3.phpt
diff -u php-src/ext/standard/tests/strings/setlocale_variation3.phpt:1.1.4.2 

[PHP-CVS] cvs: php-src /ext/standard/tests/strings moneyformat.phpt

2008-01-27 Thread Nuno Lopes
nlopess Sun Jan 27 16:54:02 2008 UTC

  Modified files:  
/php-src/ext/standard/tests/strings moneyformat.phpt 
  Log:
  be more strict in the skipif
  
http://cvs.php.net/viewvc.cgi/php-src/ext/standard/tests/strings/moneyformat.phpt?r1=1.5r2=1.6diff_format=u
Index: php-src/ext/standard/tests/strings/moneyformat.phpt
diff -u php-src/ext/standard/tests/strings/moneyformat.phpt:1.5 
php-src/ext/standard/tests/strings/moneyformat.phpt:1.6
--- php-src/ext/standard/tests/strings/moneyformat.phpt:1.5 Sun Jan 27 
16:52:34 2008
+++ php-src/ext/standard/tests/strings/moneyformat.phpt Sun Jan 27 16:54:02 2008
@@ -6,7 +6,7 @@
die(SKIP money_format - not supported\n);
}
 
-if (setlocale(LC_MONETARY, 'en_US') == false) {
+if (setlocale(LC_MONETARY, 'en_US') === false) {
die('skip en_US locale not available');
 }
 ?

-- 
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/strings moneyformat.phpt

2008-01-27 Thread Nuno Lopes
nlopess Sun Jan 27 16:54:22 2008 UTC

  Modified files:  (Branch: PHP_5_3)
/php-src/ext/standard/tests/strings moneyformat.phpt 
  Log:
  be more strict in the skipif
  
http://cvs.php.net/viewvc.cgi/php-src/ext/standard/tests/strings/moneyformat.phpt?r1=1.1.2.2.2.1r2=1.1.2.2.2.2diff_format=u
Index: php-src/ext/standard/tests/strings/moneyformat.phpt
diff -u php-src/ext/standard/tests/strings/moneyformat.phpt:1.1.2.2.2.1 
php-src/ext/standard/tests/strings/moneyformat.phpt:1.1.2.2.2.2
--- php-src/ext/standard/tests/strings/moneyformat.phpt:1.1.2.2.2.1 Sun Jan 
27 16:45:43 2008
+++ php-src/ext/standard/tests/strings/moneyformat.phpt Sun Jan 27 16:54:22 2008
@@ -6,7 +6,7 @@
die(SKIP money_format - not supported\n);
}
 
-if (setlocale(LC_MONETARY, 'en_US') == false) {
+if (setlocale(LC_MONETARY, 'en_US') === false) {
die('skip en_US locale not available');
 }
 ?

-- 
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/tests bug43003.phpt

2008-01-27 Thread Nuno Lopes
nlopess Sun Jan 27 17:01:11 2008 UTC

  Modified files:  (Branch: PHP_5_3)
/php-src/ext/date/tests bug43003.phpt 
  Log:
  fix test
  
http://cvs.php.net/viewvc.cgi/php-src/ext/date/tests/bug43003.phpt?r1=1.1.2.2r2=1.1.2.3diff_format=u
Index: php-src/ext/date/tests/bug43003.phpt
diff -u php-src/ext/date/tests/bug43003.phpt:1.1.2.2 
php-src/ext/date/tests/bug43003.phpt:1.1.2.3
--- php-src/ext/date/tests/bug43003.phpt:1.1.2.2Thu Jan 17 19:59:00 2008
+++ php-src/ext/date/tests/bug43003.phptSun Jan 27 17:01:11 2008
@@ -2,6 +2,8 @@
 Bug #43003 (Invalid timezone reported for DateTime objects constructed using a 
timestamp)
 --FILE--
 ?php
+date_default_timezone_set('Europe/Oslo');
+
 $oDateTest = new DateTime(@0, new DateTimeZone(date_default_timezone_get()));
 echo $oDateTest-getTimezone()-getName().:  .  $oDateTest-format(Y-m-d 
H:i:s).\n;
 

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



[PHP-CVS] cvs: php-src /ext/date/tests bug43003.phpt

2008-01-27 Thread Nuno Lopes
nlopess Sun Jan 27 17:02:01 2008 UTC

  Modified files:  
/php-src/ext/date/tests bug43003.phpt 
  Log:
  fix test
  
http://cvs.php.net/viewvc.cgi/php-src/ext/date/tests/bug43003.phpt?r1=1.1r2=1.2diff_format=u
Index: php-src/ext/date/tests/bug43003.phpt
diff -u php-src/ext/date/tests/bug43003.phpt:1.1 
php-src/ext/date/tests/bug43003.phpt:1.2
--- php-src/ext/date/tests/bug43003.phpt:1.1Thu Jan 17 19:58:24 2008
+++ php-src/ext/date/tests/bug43003.phptSun Jan 27 17:02:01 2008
@@ -2,6 +2,8 @@
 Bug #43003 (Invalid timezone reported for DateTime objects constructed using a 
timestamp)
 --FILE--
 ?php
+date_default_timezone_set('Europe/Oslo');
+
 $oDateTest = new DateTime(@0, new DateTimeZone(date_default_timezone_get()));
 echo $oDateTest-getTimezone()-getName().:  .  $oDateTest-format(Y-m-d 
H:i:s).\n;
 

-- 
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/strings moneyformat.phpt setlocale_basic1.phpt setlocale_basic2.phpt setlocale_basic3.phpt setlocale_variation1.phpt setlocale_variation3.phpt setlocale_vari

2008-01-27 Thread Nuno Lopes
nlopess Sun Jan 27 16:52:34 2008 UTC

  Modified files:  
/php-src/ext/standard/tests/strings moneyformat.phpt 
setlocale_basic1.phpt 
setlocale_basic2.phpt 
setlocale_basic3.phpt 
setlocale_variation1.phpt 
setlocale_variation3.phpt 
setlocale_variation4.phpt 
setlocale_variation5.phpt 
  Log:
  MFB: fix skipifs
  
http://cvs.php.net/viewvc.cgi/php-src/ext/standard/tests/strings/moneyformat.phpt?r1=1.4r2=1.5diff_format=u
Index: php-src/ext/standard/tests/strings/moneyformat.phpt
diff -u php-src/ext/standard/tests/strings/moneyformat.phpt:1.4 
php-src/ext/standard/tests/strings/moneyformat.phpt:1.5
--- php-src/ext/standard/tests/strings/moneyformat.phpt:1.4 Mon Oct  1 
12:01:28 2007
+++ php-src/ext/standard/tests/strings/moneyformat.phpt Sun Jan 27 16:52:34 2008
@@ -5,6 +5,10 @@
if (!function_exists('money_format') || !function_exists('setlocale')) {
die(SKIP money_format - not supported\n);
}
+
+if (setlocale(LC_MONETARY, 'en_US') == false) {
+   die('skip en_US locale not available');
+}
 ?
 --FILE--
 ?php
http://cvs.php.net/viewvc.cgi/php-src/ext/standard/tests/strings/setlocale_basic1.phpt?r1=1.3r2=1.4diff_format=u
Index: php-src/ext/standard/tests/strings/setlocale_basic1.phpt
diff -u php-src/ext/standard/tests/strings/setlocale_basic1.phpt:1.3 
php-src/ext/standard/tests/strings/setlocale_basic1.phpt:1.4
--- php-src/ext/standard/tests/strings/setlocale_basic1.phpt:1.3Wed Dec 
19 10:37:42 2007
+++ php-src/ext/standard/tests/strings/setlocale_basic1.phptSun Jan 27 
16:52:34 2008
@@ -7,6 +7,9 @@
 
 if( ini_get(unicode.semantics) == 1)
   die('skip do not run when unicode on');
+
+if (setlocale(LC_ALL, en_US.utf8, en_AU.utf8, ko_KR.utf8, zh_CN.utf8, 
de_DE.utf8, es_EC.utf8, fr_FR.utf8, ja_JP.utf8, el_GR.utf8, 
nl_NL.utf8) === false)
+  die('skip available locales not usable');
 ?
 --FILE--
 ?php
http://cvs.php.net/viewvc.cgi/php-src/ext/standard/tests/strings/setlocale_basic2.phpt?r1=1.2r2=1.3diff_format=u
Index: php-src/ext/standard/tests/strings/setlocale_basic2.phpt
diff -u php-src/ext/standard/tests/strings/setlocale_basic2.phpt:1.2 
php-src/ext/standard/tests/strings/setlocale_basic2.phpt:1.3
--- php-src/ext/standard/tests/strings/setlocale_basic2.phpt:1.2Fri Oct 
 5 19:35:45 2007
+++ php-src/ext/standard/tests/strings/setlocale_basic2.phptSun Jan 27 
16:52:34 2008
@@ -6,6 +6,8 @@
   die('skip Not valid for windows');
 if(ini_get(unicode.semantics) == 1)
   die('skip do not run when unicode on');
+if (setlocale(LC_ALL, en_US.utf8, en_AU.utf8, ko_KR.utf8, zh_CN.utf8, 
de_DE.utf8, es_EC.utf8, fr_FR.utf8, ja_JP.utf8, el_GR.utf8, 
nl_NL.utf8) === false)
+  die('skip available locales not usable');
 ?
 --FILE--
 ?php
http://cvs.php.net/viewvc.cgi/php-src/ext/standard/tests/strings/setlocale_basic3.phpt?r1=1.2r2=1.3diff_format=u
Index: php-src/ext/standard/tests/strings/setlocale_basic3.phpt
diff -u php-src/ext/standard/tests/strings/setlocale_basic3.phpt:1.2 
php-src/ext/standard/tests/strings/setlocale_basic3.phpt:1.3
--- php-src/ext/standard/tests/strings/setlocale_basic3.phpt:1.2Fri Oct 
 5 19:35:45 2007
+++ php-src/ext/standard/tests/strings/setlocale_basic3.phptSun Jan 27 
16:52:34 2008
@@ -6,6 +6,8 @@
   die('skip Not valid for windows');
 if(ini_get(unicode.semantics) == 1)
   die('skip do not run when unicode on');
+if (setlocale(LC_ALL, en_US.utf8, Ko_KR.utf8, zh_CN.utf8) === false)
+  die('skip en_US.utf8/Ko_KR.utf8/zh_CN.utf8 locales not available');
 ?
 --FILE--
 ?php
http://cvs.php.net/viewvc.cgi/php-src/ext/standard/tests/strings/setlocale_variation1.phpt?r1=1.2r2=1.3diff_format=u
Index: php-src/ext/standard/tests/strings/setlocale_variation1.phpt
diff -u php-src/ext/standard/tests/strings/setlocale_variation1.phpt:1.2 
php-src/ext/standard/tests/strings/setlocale_variation1.phpt:1.3
--- php-src/ext/standard/tests/strings/setlocale_variation1.phpt:1.2Fri Oct 
 5 19:35:45 2007
+++ php-src/ext/standard/tests/strings/setlocale_variation1.phptSun Jan 
27 16:52:34 2008
@@ -6,6 +6,8 @@
   die('skip Not valid for windows');
 if(ini_get(unicode.semantics) == 1)
   die('skip do not run when unicode on');
+if (setlocale(LC_ALL, en_US.utf8, Ko_KR.utf8, zh_CN.utf8) === false)
+  die('skip en_US.utf8/Ko_KR.utf8/zh_CN.utf8 locales not available');
 ?
 --FILE--
 ?php
http://cvs.php.net/viewvc.cgi/php-src/ext/standard/tests/strings/setlocale_variation3.phpt?r1=1.2r2=1.3diff_format=u
Index: php-src/ext/standard/tests/strings/setlocale_variation3.phpt
diff -u php-src/ext/standard/tests/strings/setlocale_variation3.phpt:1.2 
php-src/ext/standard/tests/strings/setlocale_variation3.phpt:1.3
--- 

Re: [PHP-CVS] cvs: php-src /ext/spl php_spl.c php_spl.h /ext/tidy php_tidy.h tidy.c

2008-01-27 Thread Nuno Lopes
Thank you for reverting this. It seems that the Zend engine really requires 
right access to these structures. The engine needs fixing first.

Thanks,
Nuno

- Original Message - 
From: Marcus Boerger [EMAIL PROTECTED]

To: php-cvs@lists.php.net
Sent: Sunday, January 27, 2008 3:03 PM
Subject: [PHP-CVS] cvs: php-src /ext/spl php_spl.c php_spl.h /ext/tidy 
php_tidy.h tidy.c




helly Sun Jan 27 15:03:55 2008 UTC

 Modified files:
   /php-src/ext/spl php_spl.c php_spl.h
   /php-src/ext/tidy php_tidy.h tidy.c
 Log:
 - revert over constfying

http://cvs.php.net/viewvc.cgi/php-src/ext/spl/php_spl.c?r1=1.121r2=1.122diff_format=u
Index: php-src/ext/spl/php_spl.c
diff -u php-src/ext/spl/php_spl.c:1.121 php-src/ext/spl/php_spl.c:1.122
--- php-src/ext/spl/php_spl.c:1.121 Fri Jan 25 20:30:36 2008
+++ php-src/ext/spl/php_spl.c Sun Jan 27 15:03:55 2008
@@ -16,7 +16,7 @@

+--+
 */

-/* $Id: php_spl.c,v 1.121 2008/01/25 20:30:36 nlopess Exp $ */
+/* $Id: php_spl.c,v 1.122 2008/01/27 15:03:55 helly Exp $ */

#ifdef HAVE_CONFIG_H
#include config.h
@@ -781,7 +781,7 @@

/* {{{ spl_module_entry
 */
-const zend_module_entry spl_module_entry = {
+zend_module_entry spl_module_entry = {
#ifdef HAVE_SIMPLEXML
 STANDARD_MODULE_HEADER_EX, NULL,
 spl_deps,
http://cvs.php.net/viewvc.cgi/php-src/ext/spl/php_spl.h?r1=1.25r2=1.26diff_format=u
Index: php-src/ext/spl/php_spl.h
diff -u php-src/ext/spl/php_spl.h:1.25 php-src/ext/spl/php_spl.h:1.26
--- php-src/ext/spl/php_spl.h:1.25 Fri Jan 25 20:30:36 2008
+++ php-src/ext/spl/php_spl.h Sun Jan 27 15:03:55 2008
@@ -28,7 +28,7 @@
#define SPL_DEBUG(x)
#endif

-extern const zend_module_entry spl_module_entry;
+extern zend_module_entry spl_module_entry;
#define phpext_spl_ptr spl_module_entry

#ifdef PHP_WIN32
http://cvs.php.net/viewvc.cgi/php-src/ext/tidy/php_tidy.h?r1=1.37r2=1.38diff_format=u
Index: php-src/ext/tidy/php_tidy.h
diff -u php-src/ext/tidy/php_tidy.h:1.37 php-src/ext/tidy/php_tidy.h:1.38
--- php-src/ext/tidy/php_tidy.h:1.37 Fri Jan 25 20:30:36 2008
+++ php-src/ext/tidy/php_tidy.h Sun Jan 27 15:03:55 2008
@@ -16,12 +16,12 @@
  +--+
*/

-/* $Id: php_tidy.h,v 1.37 2008/01/25 20:30:36 nlopess Exp $ */
+/* $Id: php_tidy.h,v 1.38 2008/01/27 15:03:55 helly Exp $ */

#ifndef PHP_TIDY_H
#define PHP_TIDY_H

-extern const zend_module_entry tidy_module_entry;
+extern zend_module_entry tidy_module_entry;
#define phpext_tidy_ptr tidy_module_entry

#define TIDY_METHOD_MAP(name, func_name, arg_types) \
http://cvs.php.net/viewvc.cgi/php-src/ext/tidy/tidy.c?r1=1.119r2=1.120diff_format=u
Index: php-src/ext/tidy/tidy.c
diff -u php-src/ext/tidy/tidy.c:1.119 php-src/ext/tidy/tidy.c:1.120
--- php-src/ext/tidy/tidy.c:1.119 Fri Jan 25 20:30:36 2008
+++ php-src/ext/tidy/tidy.c Sun Jan 27 15:03:55 2008
@@ -16,7 +16,7 @@
  +--+
*/

-/* $Id: tidy.c,v 1.119 2008/01/25 20:30:36 nlopess Exp $ */
+/* $Id: tidy.c,v 1.120 2008/01/27 15:03:55 helly Exp $ */

#ifdef HAVE_CONFIG_H
#include config.h
@@ -359,7 +359,7 @@
static zend_object_handlers tidy_object_handlers_doc;
static zend_object_handlers tidy_object_handlers_node;

-const zend_module_entry tidy_module_entry = {
+zend_module_entry tidy_module_entry = {
 STANDARD_MODULE_HEADER,
 tidy,
 tidy_functions,
@@ -1062,7 +1062,7 @@
 php_info_print_table_start();
 php_info_print_table_header(2, Tidy support, enabled);
 php_info_print_table_row(2, libTidy Release, (char 
*)tidyReleaseDate());
- php_info_print_table_row(2, Extension Version, PHP_TIDY_MODULE_VERSION 
 ($Id: tidy.c,v 1.119 2008/01/25 20:30:36 nlopess Exp $));
+ php_info_print_table_row(2, Extension Version, PHP_TIDY_MODULE_VERSION 
 ($Id: tidy.c,v 1.120 2008/01/27 15:03:55 helly Exp $));

 php_info_print_table_end();

 DISPLAY_INI_ENTRIES();

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


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



Re: [PHP-CVS] cvs: php-src /ext/spl php_spl.c php_spl.h /ext/tidy php_tidy.h tidy.c

2008-01-27 Thread Nuno Lopes
I'll take a look into that to see how feasible it is and if it presents any 
useful gains.


Thanks,
Nuno


- Original Message -

Hello Nuno,

 it writes the module number in the structure. We could have the macros
create a static non const int that receives the module number and 
reference
that from the struct via a pointer, which would be compatible to the 
struct

being static const then.

marcus

Sunday, January 27, 2008, 6:08:47 PM, you wrote:

Thank you for reverting this. It seems that the Zend engine really 
requires

right access to these structures. The engine needs fixing first.
Thanks,
Nuno


- Original Message - 
From: Marcus Boerger [EMAIL PROTECTED]

To: php-cvs@lists.php.net
Sent: Sunday, January 27, 2008 3:03 PM
Subject: [PHP-CVS] cvs: php-src /ext/spl php_spl.c php_spl.h /ext/tidy
php_tidy.h tidy.c




helly Sun Jan 27 15:03:55 2008 UTC

 Modified files:
   /php-src/ext/spl php_spl.c php_spl.h
   /php-src/ext/tidy php_tidy.h tidy.c
 Log:
 - revert over constfying

http://cvs.php.net/viewvc.cgi/php-src/ext/spl/php_spl.c?r1=1.121r2=1.122diff_format=u
Index: php-src/ext/spl/php_spl.c
diff -u php-src/ext/spl/php_spl.c:1.121 php-src/ext/spl/php_spl.c:1.122
--- php-src/ext/spl/php_spl.c:1.121 Fri Jan 25 20:30:36 2008
+++ php-src/ext/spl/php_spl.c Sun Jan 27 15:03:55 2008
@@ -16,7 +16,7 @@

+--+
 */

-/* $Id: php_spl.c,v 1.121 2008/01/25 20:30:36 nlopess Exp $ */
+/* $Id: php_spl.c,v 1.122 2008/01/27 15:03:55 helly Exp $ */

#ifdef HAVE_CONFIG_H
#include config.h
@@ -781,7 +781,7 @@

/* {{{ spl_module_entry
 */
-const zend_module_entry spl_module_entry = {
+zend_module_entry spl_module_entry = {
#ifdef HAVE_SIMPLEXML
 STANDARD_MODULE_HEADER_EX, NULL,
 spl_deps,
http://cvs.php.net/viewvc.cgi/php-src/ext/spl/php_spl.h?r1=1.25r2=1.26diff_format=u
Index: php-src/ext/spl/php_spl.h
diff -u php-src/ext/spl/php_spl.h:1.25 php-src/ext/spl/php_spl.h:1.26
--- php-src/ext/spl/php_spl.h:1.25 Fri Jan 25 20:30:36 2008
+++ php-src/ext/spl/php_spl.h Sun Jan 27 15:03:55 2008
@@ -28,7 +28,7 @@
#define SPL_DEBUG(x)
#endif

-extern const zend_module_entry spl_module_entry;
+extern zend_module_entry spl_module_entry;
#define phpext_spl_ptr spl_module_entry

#ifdef PHP_WIN32
http://cvs.php.net/viewvc.cgi/php-src/ext/tidy/php_tidy.h?r1=1.37r2=1.38diff_format=u
Index: php-src/ext/tidy/php_tidy.h
diff -u php-src/ext/tidy/php_tidy.h:1.37 
php-src/ext/tidy/php_tidy.h:1.38

--- php-src/ext/tidy/php_tidy.h:1.37 Fri Jan 25 20:30:36 2008
+++ php-src/ext/tidy/php_tidy.h Sun Jan 27 15:03:55 2008
@@ -16,12 +16,12 @@

+--+
*/

-/* $Id: php_tidy.h,v 1.37 2008/01/25 20:30:36 nlopess Exp $ */
+/* $Id: php_tidy.h,v 1.38 2008/01/27 15:03:55 helly Exp $ */

#ifndef PHP_TIDY_H
#define PHP_TIDY_H

-extern const zend_module_entry tidy_module_entry;
+extern zend_module_entry tidy_module_entry;
#define phpext_tidy_ptr tidy_module_entry

#define TIDY_METHOD_MAP(name, func_name, arg_types) \
http://cvs.php.net/viewvc.cgi/php-src/ext/tidy/tidy.c?r1=1.119r2=1.120diff_format=u
Index: php-src/ext/tidy/tidy.c
diff -u php-src/ext/tidy/tidy.c:1.119 php-src/ext/tidy/tidy.c:1.120
--- php-src/ext/tidy/tidy.c:1.119 Fri Jan 25 20:30:36 2008
+++ php-src/ext/tidy/tidy.c Sun Jan 27 15:03:55 2008
@@ -16,7 +16,7 @@

+--+
*/

-/* $Id: tidy.c,v 1.119 2008/01/25 20:30:36 nlopess Exp $ */
+/* $Id: tidy.c,v 1.120 2008/01/27 15:03:55 helly Exp $ */

#ifdef HAVE_CONFIG_H
#include config.h
@@ -359,7 +359,7 @@
static zend_object_handlers tidy_object_handlers_doc;
static zend_object_handlers tidy_object_handlers_node;

-const zend_module_entry tidy_module_entry = {
+zend_module_entry tidy_module_entry = {
 STANDARD_MODULE_HEADER,
 tidy,
 tidy_functions,
@@ -1062,7 +1062,7 @@
 php_info_print_table_start();
 php_info_print_table_header(2, Tidy support, enabled);
 php_info_print_table_row(2, libTidy Release, (char
*)tidyReleaseDate());
- php_info_print_table_row(2, Extension Version, 
PHP_TIDY_MODULE_VERSION

 ($Id: tidy.c,v 1.119 2008/01/25 20:30:36 nlopess Exp $));
+ php_info_print_table_row(2, Extension Version, 
PHP_TIDY_MODULE_VERSION

 ($Id: tidy.c,v 1.120 2008/01/27 15:03:55 helly Exp $));
 php_info_print_table_end();

 DISPLAY_INI_ENTRIES(); 


--
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/mysql php_mysql_structs.h

2008-01-28 Thread Nuno Lopes
nlopess Mon Jan 28 11:16:00 2008 UTC

  Modified files:  (Branch: PHP_5_3)
/php-src/ext/mysql  php_mysql_structs.h 
  Log:
  remove unused PHP_MYSQL_API macro
  
http://cvs.php.net/viewvc.cgi/php-src/ext/mysql/php_mysql_structs.h?r1=1.1.2.2r2=1.1.2.3diff_format=u
Index: php-src/ext/mysql/php_mysql_structs.h
diff -u php-src/ext/mysql/php_mysql_structs.h:1.1.2.2 
php-src/ext/mysql/php_mysql_structs.h:1.1.2.3
--- php-src/ext/mysql/php_mysql_structs.h:1.1.2.2   Mon Dec 31 07:17:10 2007
+++ php-src/ext/mysql/php_mysql_structs.h   Mon Jan 28 11:16:00 2008
@@ -18,17 +18,11 @@
 */
 
 
-/* $Id: php_mysql_structs.h,v 1.1.2.2 2007/12/31 07:17:10 sebastian Exp $ */
+/* $Id: php_mysql_structs.h,v 1.1.2.3 2008/01/28 11:16:00 nlopess Exp $ */
 
 #ifndef PHP_MYSQL_STRUCTS_H
 #define PHP_MYSQL_STRUCTS_H
 
-#ifdef PHP_WIN32
-#define PHP_MYSQL_API __declspec(dllexport)
-#else
-#define PHP_MYSQL_API
-#endif
-
 #ifdef ZTS
 #include TSRM.h
 #endif

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



  1   2   3   4   5   6   7   >