[PHP-CVS] cvs: php-src / acinclude.m4

2007-07-16 Thread Jani Taskinen
janiMon Jul 16 10:00:31 2007 UTC

  Modified files:  
/php-srcacinclude.m4 
  Log:
  - Fix issue in differentiating between --with-* and --enable-*
  
http://cvs.php.net/viewvc.cgi/php-src/acinclude.m4?r1=1.376r2=1.377diff_format=u
Index: php-src/acinclude.m4
diff -u php-src/acinclude.m4:1.376 php-src/acinclude.m4:1.377
--- php-src/acinclude.m4:1.376  Thu Jul 12 17:46:14 2007
+++ php-src/acinclude.m4Mon Jul 16 10:00:31 2007
@@ -1,5 +1,5 @@
 dnl
-dnl $Id: acinclude.m4,v 1.376 2007/07/12 17:46:14 jani Exp $
+dnl $Id: acinclude.m4,v 1.377 2007/07/16 10:00:31 jani Exp $
 dnl
 dnl This file contains local autoconf functions.
 dnl
@@ -696,6 +696,7 @@
 dnl the PHP_ARG_ANALYZE_EX.
 dnl
 AC_DEFUN([PHP_ARG_WITH],[
+php_with_[]translit($1,A-Z0-9-,a-z0-9_)=ifelse($4,,no,$4)
 
PHP_REAL_ARG_WITH([$1],[$2],[$3],[$4],PHP_[]translit($1,a-z0-9-,A-Z0-9_),[ifelse($5,,yes,$5)])
 ])
 
@@ -723,7 +724,8 @@
 dnl the PHP_ARG_ANALYZE_EX.
 dnl
 AC_DEFUN([PHP_ARG_ENABLE],[
-PHP_REAL_ARG_ENABLE([$1],[$2],[$3],[$4],PHP_[]translit($1,a-z-,A-Z_),[ifelse($5,,yes,$5)])
+php_enable_[]translit($1,A-Z0-9-,a-z0-9_)=ifelse($4,,no,$4)
+PHP_REAL_ARG_ENABLE([$1],[$2],[$3],[$4],PHP_[]translit($1,a-z0-9-,A-Z0-9_),[ifelse($5,,yes,$5)])
 ])
 
 dnl PHP_REAL_ARG_ENABLE
@@ -2617,16 +2619,16 @@
   for arg in $ac_configure_args; do
 case $arg in
   --with-*[)]
-   arg_name=`echo [$]arg | $SED -e 's/--with-//g' -e 's/=.*//g'`
+   arg_name=`echo [$]arg | $SED -e 's/--with-/with-/g' -e 's/=.*//g'`
 ;;
   --without-*[)]
-   arg_name=`echo [$]arg | $SED -e 's/--without-//g' -e 's/=.*//g'`
+   arg_name=`echo [$]arg | $SED -e 's/--without-/with-/g' -e 's/=.*//g'`
 ;;
   --enable-*[)]
-   arg_name=`echo [$]arg | $SED -e 's/--enable-//g' -e 's/=.*//g'`
+   arg_name=`echo [$]arg | $SED -e 's/--enable-/enable-/g' -e 's/=.*//g'`
 ;;
   --disable-*[)]
-   arg_name=`echo [$]arg | $SED -e 's/--disable-//g' -e 's/=.*//g'`
+   arg_name=`echo [$]arg | $SED -e 's/--disable-/enable-/g' -e 
's/=.*//g'`
 ;;
   *[)]
continue
@@ -2634,20 +2636,21 @@
 esac
 case $arg_name in
   # Allow --disable-all / --enable-all
-  all[)];;
+  enable-all[)];;
 
   # Allow certain libtool options
-  libtool-lock | pic | tags | shared | static | fast-install | gnu-ld[)];;
+  enable-libtool-lock | with-pic | with-tags | enable-shared | 
enable-static | enable-fast-install | with-gnu-ld[)];;
 
   # Allow certain TSRM options
-  tsrm-pth | tsrm-st | tsrm-pthreads[)];;
+  with-tsrm-pth | with-tsrm-st | with-tsrm-pthreads[)];;
 
   # Allow certain Zend options
-  zend-vm | maintainer-zts | inline-optimization | zend-multibyte[)];;
+  with-zend-vm | enable-maintainer-zts | enable-inline-optimization | 
enable-zend-multibyte[)];;
 
   # All the rest must be set using the PHP_ARG_* macros
+  # PHP_ARG_* macros set php_enable_arg_name or php_with_arg_name
   *[)]
-is_arg_set=PHP_[]`echo [$]arg_name | tr 'abcdefghijklmnopqrstuvwxyz-' 
'ABCDEFGHIJKLMNOPQRSTUVWXYZ_'`
+is_arg_set=php_[]`echo [$]arg_name | tr 'ABCDEFGHIJKLMNOPQRSTUVWXYZ-' 
'abcdefghijklmnopqrstuvwxyz_'`
 if eval test -z \$$is_arg_set; then
   PHP_UNKNOWN_CONFIGURE_OPTIONS=$PHP_UNKNOWN_CONFIGURE_OPTIONS
 [$]arg

-- 
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) / acinclude.m4

2007-07-16 Thread Jani Taskinen
janiMon Jul 16 10:00:44 2007 UTC

  Modified files:  (Branch: PHP_5_2)
/php-srcacinclude.m4 
  Log:
  - Fix issue in differentiating between --with-* and --enable-*
  
http://cvs.php.net/viewvc.cgi/php-src/acinclude.m4?r1=1.332.2.14.2.20r2=1.332.2.14.2.21diff_format=u
Index: php-src/acinclude.m4
diff -u php-src/acinclude.m4:1.332.2.14.2.20 
php-src/acinclude.m4:1.332.2.14.2.21
--- php-src/acinclude.m4:1.332.2.14.2.20Wed Jul 11 17:36:55 2007
+++ php-src/acinclude.m4Mon Jul 16 10:00:44 2007
@@ -1,5 +1,5 @@
 dnl
-dnl $Id: acinclude.m4,v 1.332.2.14.2.20 2007/07/11 17:36:55 johannes Exp $
+dnl $Id: acinclude.m4,v 1.332.2.14.2.21 2007/07/16 10:00:44 jani Exp $
 dnl
 dnl This file contains local autoconf functions.
 dnl
@@ -696,6 +696,7 @@
 dnl the PHP_ARG_ANALYZE_EX.
 dnl
 AC_DEFUN([PHP_ARG_WITH],[
+php_with_[]translit($1,A-Z0-9-,a-z0-9_)=ifelse($4,,no,$4)
 
PHP_REAL_ARG_WITH([$1],[$2],[$3],[$4],PHP_[]translit($1,a-z0-9-,A-Z0-9_),[ifelse($5,,yes,$5)])
 ])
 
@@ -723,7 +724,8 @@
 dnl the PHP_ARG_ANALYZE_EX.
 dnl
 AC_DEFUN([PHP_ARG_ENABLE],[
-PHP_REAL_ARG_ENABLE([$1],[$2],[$3],[$4],PHP_[]translit($1,a-z-,A-Z_),[ifelse($5,,yes,$5)])
+php_enable_[]translit($1,A-Z0-9-,a-z0-9_)=ifelse($4,,no,$4)
+PHP_REAL_ARG_ENABLE([$1],[$2],[$3],[$4],PHP_[]translit($1,a-z0-9-,A-Z0-9_),[ifelse($5,,yes,$5)])
 ])
 
 dnl PHP_REAL_ARG_ENABLE
@@ -2563,16 +2565,16 @@
   for arg in $ac_configure_args; do
 case $arg in
   --with-*[)]
-   arg_name=`echo [$]arg | $SED -e 's/--with-//g' -e 's/=.*//g'`
+   arg_name=`echo [$]arg | $SED -e 's/--with-/with-/g' -e 's/=.*//g'`
 ;;
   --without-*[)]
-   arg_name=`echo [$]arg | $SED -e 's/--without-//g' -e 's/=.*//g'`
+   arg_name=`echo [$]arg | $SED -e 's/--without-/with-/g' -e 's/=.*//g'`
 ;;
   --enable-*[)]
-   arg_name=`echo [$]arg | $SED -e 's/--enable-//g' -e 's/=.*//g'`
+   arg_name=`echo [$]arg | $SED -e 's/--enable-/enable-/g' -e 's/=.*//g'`
 ;;
   --disable-*[)]
-   arg_name=`echo [$]arg | $SED -e 's/--disable-//g' -e 's/=.*//g'`
+   arg_name=`echo [$]arg | $SED -e 's/--disable-/enable-/g' -e 
's/=.*//g'`
 ;;
   *[)]
continue
@@ -2580,20 +2582,21 @@
 esac
 case $arg_name in
   # Allow --disable-all / --enable-all
-  all[)];;
+  enable-all[)];;
 
   # Allow certain libtool options
-  libtool-lock | pic | tags | shared | static | fast-install | gnu-ld[)];;
+  enable-libtool-lock | with-pic | with-tags | enable-shared | 
enable-static | enable-fast-install | with-gnu-ld[)];;
 
   # Allow certain TSRM options
-  tsrm-pth | tsrm-st | tsrm-pthreads[)];;
+  with-tsrm-pth | with-tsrm-st | with-tsrm-pthreads[)];;
 
   # Allow certain Zend options
-  zend-vm | maintainer-zts | inline-optimization | zend-multibyte[)];;
+  with-zend-vm | enable-maintainer-zts | enable-inline-optimization | 
enable-zend-multibyte[)];;
 
   # All the rest must be set using the PHP_ARG_* macros
+  # PHP_ARG_* macros set php_enable_arg_name or php_with_arg_name
   *[)]
-is_arg_set=PHP_[]`echo [$]arg_name | tr 'abcdefghijklmnopqrstuvwxyz-' 
'ABCDEFGHIJKLMNOPQRSTUVWXYZ_'`
+is_arg_set=php_[]`echo [$]arg_name | tr 'ABCDEFGHIJKLMNOPQRSTUVWXYZ-' 
'abcdefghijklmnopqrstuvwxyz_'`
 if eval test -z \$$is_arg_set; then
   PHP_UNKNOWN_CONFIGURE_OPTIONS=$PHP_UNKNOWN_CONFIGURE_OPTIONS
 [$]arg

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



[PHP-CVS] cvs: php-src / acinclude.m4

2007-07-16 Thread Jani Taskinen
janiMon Jul 16 10:11:39 2007 UTC

  Modified files:  
/php-srcacinclude.m4 
  Log:
  - The --enable-zend-multibyte option does not exist in PHP 6
  
http://cvs.php.net/viewvc.cgi/php-src/acinclude.m4?r1=1.377r2=1.378diff_format=u
Index: php-src/acinclude.m4
diff -u php-src/acinclude.m4:1.377 php-src/acinclude.m4:1.378
--- php-src/acinclude.m4:1.377  Mon Jul 16 10:00:31 2007
+++ php-src/acinclude.m4Mon Jul 16 10:11:39 2007
@@ -1,5 +1,5 @@
 dnl
-dnl $Id: acinclude.m4,v 1.377 2007/07/16 10:00:31 jani Exp $
+dnl $Id: acinclude.m4,v 1.378 2007/07/16 10:11:39 jani Exp $
 dnl
 dnl This file contains local autoconf functions.
 dnl
@@ -2645,7 +2645,7 @@
   with-tsrm-pth | with-tsrm-st | with-tsrm-pthreads[)];;
 
   # Allow certain Zend options
-  with-zend-vm | enable-maintainer-zts | enable-inline-optimization | 
enable-zend-multibyte[)];;
+  with-zend-vm | enable-maintainer-zts | enable-inline-optimization[)];;
 
   # All the rest must be set using the PHP_ARG_* macros
   # PHP_ARG_* macros set php_enable_arg_name or php_with_arg_name


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

2007-07-16 Thread Antony Dovgal
tony2001Mon Jul 16 10:37:02 2007 UTC

  Modified files:  
/php-src/ext/standard/tests/filebug41815.phpt 
  Log:
  fix test
  
  
http://cvs.php.net/viewvc.cgi/php-src/ext/standard/tests/file/bug41815.phpt?r1=1.2r2=1.3diff_format=u
Index: php-src/ext/standard/tests/file/bug41815.phpt
diff -u php-src/ext/standard/tests/file/bug41815.phpt:1.2 
php-src/ext/standard/tests/file/bug41815.phpt:1.3
--- php-src/ext/standard/tests/file/bug41815.phpt:1.2   Thu Jul 12 11:07:29 2007
+++ php-src/ext/standard/tests/file/bug41815.phpt   Mon Jul 16 10:37:02 2007
@@ -6,7 +6,7 @@
 $filename = dirname(__FILE__)./concur_rw.txt;
 
 @unlink($filename);
-$writer = fopen($filename, w);
+$writer = fopen($filename, wt);
 $reader = fopen($filename, r);
 fread($reader, 1);
 fwrite($writer, foo);

-- 
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/serialize bug37947.phpt

2007-07-16 Thread Antony Dovgal
tony2001Mon Jul 16 10:39:34 2007 UTC

  Modified files:  
/php-src/ext/standard/tests/serialize   bug37947.phpt 
  Log:
  fix test
  
  
http://cvs.php.net/viewvc.cgi/php-src/ext/standard/tests/serialize/bug37947.phpt?r1=1.2r2=1.3diff_format=u
Index: php-src/ext/standard/tests/serialize/bug37947.phpt
diff -u php-src/ext/standard/tests/serialize/bug37947.phpt:1.2 
php-src/ext/standard/tests/serialize/bug37947.phpt:1.3
--- php-src/ext/standard/tests/serialize/bug37947.phpt:1.2  Mon Jul 10 
14:02:54 2006
+++ php-src/ext/standard/tests/serialize/bug37947.phpt  Mon Jul 16 10:39:34 2007
@@ -3,7 +3,7 @@
 --INI--
 error_reporting=0
 --FILE--
-?
+?php
 class test {
 function extend_zend_ptr_stack($count,$a,$b,$c,$d,$e) {
 if ($count0) $this-extend_zend_ptr_stack($count -
@@ -17,5 +17,6 @@
 
 $str='a:2:{i:0;O:4:test:0:{}junk';
 var_dump(unserialize($str));
+?
 --EXPECT--
 bool(false)

-- 
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 substr_count.phpt substr_count_basic.phpt substr_count_error.phpt substr_count_variation_001.phpt substr_count_variation_002.phpt

2007-07-16 Thread Antony Dovgal
tony2001Mon Jul 16 10:59:08 2007 UTC

  Added files: 
/php-src/ext/standard/tests/strings substr_count_basic.phpt 
substr_count_error.phpt 
substr_count_variation_001.phpt 
substr_count_variation_002.phpt 

  Removed files:   
/php-src/ext/standard/tests/strings substr_count.phpt 
  Log:
  split test
  
  
http://cvs.php.net/viewvc.cgi/php-src/ext/standard/tests/strings/substr_count_basic.phpt?view=markuprev=1.1
Index: php-src/ext/standard/tests/strings/substr_count_basic.phpt
+++ php-src/ext/standard/tests/strings/substr_count_basic.phpt
--TEST--
Test substr_count() function (basic)
--FILE--
?php

echo ***Testing basic operations ***\n;
var_dump(@substr_count(, ));
var_dump(@substr_count(a, ));
var_dump(@substr_count(, a));
var_dump(@substr_count(, a));
var_dump(@substr_count(, chr(0)));
$a = str_repeat(abcacba, 100);
var_dump(@substr_count($a, bca));
$a = str_repeat(abcacbabca, 100);
var_dump(@substr_count($a, bca));
var_dump(substr_count($a, bca, 200));
var_dump(substr_count($a, bca, 200, 50));

echo Done\n;  

?
--EXPECTF--
***Testing basic operations ***
bool(false)
bool(false)
int(0)
int(0)
int(0)
int(100)
int(200)
int(160)
int(10)
Done
--UEXPECTF--
***Testing basic operations ***
bool(false)
bool(false)
int(0)
int(0)
int(0)
int(100)
int(200)
int(160)
int(10)
Done

http://cvs.php.net/viewvc.cgi/php-src/ext/standard/tests/strings/substr_count_error.phpt?view=markuprev=1.1
Index: php-src/ext/standard/tests/strings/substr_count_error.phpt
+++ php-src/ext/standard/tests/strings/substr_count_error.phpt
--TEST--
Test substr_count() function (error conditions)
--FILE--
?php

echo \n*** Testing error conditions ***\n;
/* Zero argument */
var_dump( substr_count() );

/* more than expected no. of args */
var_dump( substr_count($str, t, 0, 15, 30) );

/* offset as negative value */
var_dump(substr_count($str, t, -5));

/* offset  size of the string */
var_dump(substr_count($str, t, 25));

/* Using offset and length to go beyond the size of the string: 
   Warning message expected, as length+offset  length of string */
var_dump( substr_count($str, i, 5, 15) );

/* length as Null */
var_dump( substr_count($str, t, , ) );
var_dump( substr_count($str, i, NULL, NULL) );

echo Done\n;  

?
--EXPECTF--
*** Testing error conditions ***

Warning: substr_count() expects at least 2 parameters, 0 given in %s on line %d
NULL

Notice: Undefined variable: str in %s on line %d

Warning: substr_count() expects at most 4 parameters, 5 given in %s on line %d
NULL

Notice: Undefined variable: str in %s on line %d

Warning: substr_count(): Offset should be greater than or equal to 0 in %s on 
line %d
bool(false)

Notice: Undefined variable: str in %s on line %d

Warning: substr_count(): Offset value 25 exceeds string length in %s on line %d
bool(false)

Notice: Undefined variable: str in %s on line %d

Warning: substr_count(): Offset value 5 exceeds string length in %s on line %d
bool(false)

Notice: Undefined variable: str in %s on line %d

Warning: substr_count() expects parameter 3 to be long, string given in %s on 
line %d
NULL

Notice: Undefined variable: str in %s on line %d
int(0)
Done

http://cvs.php.net/viewvc.cgi/php-src/ext/standard/tests/strings/substr_count_variation_001.phpt?view=markuprev=1.1
Index: php-src/ext/standard/tests/strings/substr_count_variation_001.phpt
+++ php-src/ext/standard/tests/strings/substr_count_variation_001.phpt
--TEST--
Test substr_count() function (variation - 1)
--FILE--
?php

echo \n*** Testing possible variations ***\n;
echo -- 3rd or 4th arg as string --\n;
$str = this is a string;
var_dump( substr_count($str, t, 5) );
var_dump( substr_count($str, t, 5, 10) );
var_dump( substr_count($str, i, 5t) );
var_dump( substr_count($str, i, 5t, 10t) );

echo \n-- 3rd or 4th arg as NULL --\n;
var_dump( substr_count($str, t, ) );
var_dump( substr_count($str, T, ) );
var_dump( substr_count($str, t, , 15) );
var_dump( substr_count($str, I, NULL) );
var_dump( substr_count($str, i, NULL, 10) );

echo \n-- overlapped substrings --\n;
var_dump( substr_count(abcabcabcabcabc, abca) ); 
var_dump( substr_count(abcabcabcabcabc, abca, 2) ); 

echo \n-- complex strings containing other than 7-bit chars --\n;
$str = chr(128).chr(129).chr(128).chr(256).chr(255).chr(254).chr(255);
var_dump(substr_count($str, chr(128)));
var_dump(substr_count($str, chr(255)));
var_dump(substr_count($str, chr(256)));

echo \n-- heredoc string --\n;
$string = EOD
abcdefghijklmnopqrstuvwxyz0123456789abcdefghijklmnopqrstuvwxyz0123456789
abcdefghijklmnopqrstuvwxyz0123456789abcdefghijklmnopqrstuvwxyz0123456789
acdefghijklmnopqrstuvwxyz0123456789abcdefghijklmnopqrstuvwxyz0123456789
acdefghijklmnopqrstuvwxyz0123456789abcdefghijklmnopqrstuvwxyz0123456789
abcdefghijklmnopqrstuvwxyz0123456789abcdefghijklmnopqrstuvwxyz0123456789

[PHP-CVS] cvs: php-src(PHP_5_2) /ext/standard/tests/strings substr_count.phpt substr_count_basic.phpt substr_count_error.phpt substr_count_variation_001.phpt substr_count_variation_002.phpt

2007-07-16 Thread Antony Dovgal
tony2001Mon Jul 16 10:59:17 2007 UTC

  Added files: (Branch: PHP_5_2)
/php-src/ext/standard/tests/strings substr_count_basic.phpt 
substr_count_error.phpt 
substr_count_variation_001.phpt 
substr_count_variation_002.phpt 

  Removed files:   
/php-src/ext/standard/tests/strings substr_count.phpt 
  Log:
  MFH: split test
  
  
http://cvs.php.net/viewvc.cgi/php-src/ext/standard/tests/strings/substr_count_basic.phpt?view=markuprev=1.1
Index: php-src/ext/standard/tests/strings/substr_count_basic.phpt
+++ php-src/ext/standard/tests/strings/substr_count_basic.phpt
--TEST--
Test substr_count() function (basic)
--FILE--
?php

echo ***Testing basic operations ***\n;
var_dump(@substr_count(, ));
var_dump(@substr_count(a, ));
var_dump(@substr_count(, a));
var_dump(@substr_count(, a));
var_dump(@substr_count(, chr(0)));
$a = str_repeat(abcacba, 100);
var_dump(@substr_count($a, bca));
$a = str_repeat(abcacbabca, 100);
var_dump(@substr_count($a, bca));
var_dump(substr_count($a, bca, 200));
var_dump(substr_count($a, bca, 200, 50));

echo Done\n;  

?
--EXPECTF--
***Testing basic operations ***
bool(false)
bool(false)
int(0)
int(0)
int(0)
int(100)
int(200)
int(160)
int(10)
Done
--UEXPECTF--
***Testing basic operations ***
bool(false)
bool(false)
int(0)
int(0)
int(0)
int(100)
int(200)
int(160)
int(10)
Done

http://cvs.php.net/viewvc.cgi/php-src/ext/standard/tests/strings/substr_count_error.phpt?view=markuprev=1.1
Index: php-src/ext/standard/tests/strings/substr_count_error.phpt
+++ php-src/ext/standard/tests/strings/substr_count_error.phpt
--TEST--
Test substr_count() function (error conditions)
--FILE--
?php

echo \n*** Testing error conditions ***\n;
/* Zero argument */
var_dump( substr_count() );

/* more than expected no. of args */
var_dump( substr_count($str, t, 0, 15, 30) );

/* offset as negative value */
var_dump(substr_count($str, t, -5));

/* offset  size of the string */
var_dump(substr_count($str, t, 25));

/* Using offset and length to go beyond the size of the string: 
   Warning message expected, as length+offset  length of string */
var_dump( substr_count($str, i, 5, 15) );

/* length as Null */
var_dump( substr_count($str, t, , ) );
var_dump( substr_count($str, i, NULL, NULL) );

echo Done\n;  

?
--EXPECTF--
*** Testing error conditions ***

Warning: substr_count() expects at least 2 parameters, 0 given in %s on line %d
NULL

Notice: Undefined variable: str in %s on line %d

Warning: substr_count() expects at most 4 parameters, 5 given in %s on line %d
NULL

Notice: Undefined variable: str in %s on line %d

Warning: substr_count(): Offset should be greater than or equal to 0 in %s on 
line %d
bool(false)

Notice: Undefined variable: str in %s on line %d

Warning: substr_count(): Offset value 25 exceeds string length in %s on line %d
bool(false)

Notice: Undefined variable: str in %s on line %d

Warning: substr_count(): Offset value 5 exceeds string length in %s on line %d
bool(false)

Notice: Undefined variable: str in %s on line %d

Warning: substr_count() expects parameter 3 to be long, string given in %s on 
line %d
NULL

Notice: Undefined variable: str in %s on line %d
int(0)
Done

http://cvs.php.net/viewvc.cgi/php-src/ext/standard/tests/strings/substr_count_variation_001.phpt?view=markuprev=1.1
Index: php-src/ext/standard/tests/strings/substr_count_variation_001.phpt
+++ php-src/ext/standard/tests/strings/substr_count_variation_001.phpt
--TEST--
Test substr_count() function (variation - 1)
--FILE--
?php

echo \n*** Testing possible variations ***\n;
echo -- 3rd or 4th arg as string --\n;
$str = this is a string;
var_dump( substr_count($str, t, 5) );
var_dump( substr_count($str, t, 5, 10) );
var_dump( substr_count($str, i, 5t) );
var_dump( substr_count($str, i, 5t, 10t) );

echo \n-- 3rd or 4th arg as NULL --\n;
var_dump( substr_count($str, t, ) );
var_dump( substr_count($str, T, ) );
var_dump( substr_count($str, t, , 15) );
var_dump( substr_count($str, I, NULL) );
var_dump( substr_count($str, i, NULL, 10) );

echo \n-- overlapped substrings --\n;
var_dump( substr_count(abcabcabcabcabc, abca) ); 
var_dump( substr_count(abcabcabcabcabc, abca, 2) ); 

echo \n-- complex strings containing other than 7-bit chars --\n;
$str = chr(128).chr(129).chr(128).chr(256).chr(255).chr(254).chr(255);
var_dump(substr_count($str, chr(128)));
var_dump(substr_count($str, chr(255)));
var_dump(substr_count($str, chr(256)));

echo \n-- heredoc string --\n;
$string = EOD
abcdefghijklmnopqrstuvwxyz0123456789abcdefghijklmnopqrstuvwxyz0123456789
abcdefghijklmnopqrstuvwxyz0123456789abcdefghijklmnopqrstuvwxyz0123456789
acdefghijklmnopqrstuvwxyz0123456789abcdefghijklmnopqrstuvwxyz0123456789
acdefghijklmnopqrstuvwxyz0123456789abcdefghijklmnopqrstuvwxyz0123456789
abcdefghijklmnopqrstuvwxyz0123456789abcdefghijklmnopqrstuvwxyz0123456789

[PHP-CVS] cvs: php-src /ext/standard/tests/file fputcsv.phpt

2007-07-16 Thread Jani Taskinen
janiMon Jul 16 12:35:33 2007 UTC

  Modified files:  
/php-src/ext/standard/tests/filefputcsv.phpt 
  Log:
  - Use explode instead of split (ereg goes bye bye..)
  
http://cvs.php.net/viewvc.cgi/php-src/ext/standard/tests/file/fputcsv.phpt?r1=1.3r2=1.4diff_format=u
Index: php-src/ext/standard/tests/file/fputcsv.phpt
diff -u php-src/ext/standard/tests/file/fputcsv.phpt:1.3 
php-src/ext/standard/tests/file/fputcsv.phpt:1.4
--- php-src/ext/standard/tests/file/fputcsv.phpt:1.3Wed Mar  8 00:43:28 2006
+++ php-src/ext/standard/tests/file/fputcsv.phptMon Jul 16 12:35:33 2007
@@ -31,7 +31,7 @@
 
 $fp = fopen($file, w);
 foreach ($list as $v) {
-   fputcsv($fp, split(',', $v));
+   fputcsv($fp, explode(',', $v));
 }
 fclose($fp);
 

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



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

2007-07-16 Thread Jani Taskinen
janiMon Jul 16 12:58:23 2007 UTC

  Modified files:  
/php-src/main   SAPI.c 
  Log:
  - Removed leftovers from nuking safe-mode
  
http://cvs.php.net/viewvc.cgi/php-src/main/SAPI.c?r1=1.225r2=1.226diff_format=u
Index: php-src/main/SAPI.c
diff -u php-src/main/SAPI.c:1.225 php-src/main/SAPI.c:1.226
--- php-src/main/SAPI.c:1.225   Fri May 25 09:19:05 2007
+++ php-src/main/SAPI.c Mon Jul 16 12:58:23 2007
@@ -18,7 +18,7 @@
+--+
 */
 
-/* $Id: SAPI.c,v 1.225 2007/05/25 09:19:05 rasmus Exp $ */
+/* $Id: SAPI.c,v 1.226 2007/07/16 12:58:23 jani Exp $ */
 
 #include ctype.h
 #include sys/stat.h
@@ -29,9 +29,6 @@
 #include php_ini.h
 #include ext/standard/php_string.h
 #include ext/standard/pageinfo.h
-#if (HAVE_PCRE || HAVE_BUNDLED_PCRE)  !defined(COMPILE_DL_PCRE)
-#include ext/pcre/php_pcre.h
-#endif
 #if HAVE_ZLIB
 #include ext/zlib/php_zlib.h
 #endif

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



[PHP-CVS] cvs: php-src /ext/mcrypt/tests basic.phpt bug37595.phpt

2007-07-16 Thread Antony Dovgal
tony2001Mon Jul 16 13:35:31 2007 UTC

  Modified files:  
/php-src/ext/mcrypt/tests   bug37595.phpt basic.phpt 
  Log:
  add skipif
  
  
http://cvs.php.net/viewvc.cgi/php-src/ext/mcrypt/tests/bug37595.phpt?r1=1.5r2=1.6diff_format=u
Index: php-src/ext/mcrypt/tests/bug37595.phpt
http://cvs.php.net/viewvc.cgi/php-src/ext/mcrypt/tests/basic.phpt?r1=1.1r2=1.2diff_format=u
Index: php-src/ext/mcrypt/tests/basic.phpt
diff -u php-src/ext/mcrypt/tests/basic.phpt:1.1 
php-src/ext/mcrypt/tests/basic.phpt:1.2
--- php-src/ext/mcrypt/tests/basic.phpt:1.1 Wed Nov 15 22:51:45 2006
+++ php-src/ext/mcrypt/tests/basic.phpt Mon Jul 16 13:35:31 2007
@@ -1,5 +1,7 @@
 --TEST--
 mcrypt basic
+--SKIPIF--
+?php if (!extension_loaded(mcrypt)) print skip; ?
 --FILE--
 ?php
 $as = mcrypt_list_algorithms();

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



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

2007-07-16 Thread Antony Dovgal
tony2001Mon Jul 16 13:37:50 2007 UTC

  Removed files:   
/php-src/ext/informix   config.w32 config.m4 
  Log:
  remove ext/informix leftovers
  
  

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



[PHP-CVS] cvs: php-src /ext/ereg config0.m4 php_regex.h /ext/ereg/regex regex_extra.h utils.h /sapi/apache php_apache_http.h /sapi/apache_hooks php_apache_http.h

2007-07-16 Thread Jani Taskinen
janiMon Jul 16 13:41:12 2007 UTC

  Removed files:   
/php-src/ext/ereg/regex regex_extra.h 

  Modified files:  
/php-src/ext/ereg   config0.m4 php_regex.h 
/php-src/ext/ereg/regex utils.h 
/php-src/sapi/apachephp_apache_http.h 
/php-src/sapi/apache_hooks  php_apache_http.h 
  Log:
  - Cleanup and simplify
  
http://cvs.php.net/viewvc.cgi/php-src/ext/ereg/config0.m4?r1=1.1r2=1.2diff_format=u
Index: php-src/ext/ereg/config0.m4
diff -u php-src/ext/ereg/config0.m4:1.1 php-src/ext/ereg/config0.m4:1.2
--- php-src/ext/ereg/config0.m4:1.1 Sun Jul 15 19:50:06 2007
+++ php-src/ext/ereg/config0.m4 Mon Jul 16 13:41:12 2007
@@ -1,11 +1,11 @@
-dnl $Id: config0.m4,v 1.1 2007/07/15 19:50:06 jani Exp $
+dnl $Id: config0.m4,v 1.2 2007/07/16 13:41:12 jani Exp $
 dnl config.m4 for extension ereg
 
 dnl
 dnl Check for regex library type
 dnl
 PHP_ARG_WITH(regex,,
-[  --with-regex=TYPE   regex library type: system, apache, php. [TYPE=php]
+[  --with-regex=TYPE   regex library type: system, php. [TYPE=php]
   WARNING: Do NOT use unless you know what you are 
doing!], php, no)
 
 case $PHP_REGEX in
@@ -16,9 +16,6 @@
   REGEX_TYPE=system
 fi
 ;;
-  apache)
-REGEX_TYPE=apache
-;;
   yes | php)
 REGEX_TYPE=php
 ;;
@@ -34,9 +31,10 @@
 if test $REGEX_TYPE = php; then
   ereg_regex_sources=regex/regcomp.c regex/regexec.c regex/regerror.c 
regex/regfree.c
   ereg_regex_headers=regex/
+  PHP_EREG_CFLAGS=-Dregexec=php_regexec -Dregerror=php_regerror 
-Dregfree=php_regfree -Dregcomp=php_regcomp
 fi
 
-PHP_NEW_EXTENSION(ereg, ereg.c $ereg_regex_sources, no)
+PHP_NEW_EXTENSION(ereg, ereg.c $ereg_regex_sources, no,,$PHP_EREG_CFLAGS)
 PHP_INSTALL_HEADERS([ext/ereg], [php_ereg.h php_regex.h $ereg_regex_headers])
 
 if test $REGEX_TYPE = php; then
http://cvs.php.net/viewvc.cgi/php-src/ext/ereg/php_regex.h?r1=1.19r2=1.20diff_format=u
Index: php-src/ext/ereg/php_regex.h
diff -u php-src/ext/ereg/php_regex.h:1.19 php-src/ext/ereg/php_regex.h:1.20
--- php-src/ext/ereg/php_regex.h:1.19   Sun Jul 15 19:50:06 2007
+++ php-src/ext/ereg/php_regex.hMon Jul 16 13:41:12 2007
@@ -16,7 +16,7 @@
   +--+
 */
 
-/* $Id: php_regex.h,v 1.19 2007/07/15 19:50:06 jani Exp $ */
+/* $Id: php_regex.h,v 1.20 2007/07/16 13:41:12 jani Exp $ */
 
 #ifndef PHP_REGEX_H
 #define PHP_REGEX_H
@@ -27,15 +27,14 @@
  * 1.. bundled regex
  */
 
-#if REGEX
-/* get aliases */
-#include ext/ereg/regex/regex_extra.h
-#include ext/ereg/regex/regex.h
+#if (REGEX == 1)
+/* Define aliases */
+#define regexec php_regexec
+#define regerror php_regerror
+#define regfree php_regfree
+#define regcomp php_regcomp
 
-/* get rid of aliases */
-#define PHP_NO_ALIASES
-#include ext/ereg/regex/regex_extra.h
-#undef PHP_NO_ALIASES
+#include ext/ereg/regex/regex.h
 
 #undef _PCREPOSIX_H
 #define _PCREPOSIX_H 1
@@ -55,6 +54,7 @@
 #ifndef _H_REGEX
 #define _H_REGEX 1  /* This one is for AIX */
 #endif
+
 #elif REGEX == 0
 #include regex.h
 #ifndef _REGEX_H_
@@ -63,8 +63,3 @@
 #endif
 
 #endif /* PHP_REGEX_H */
-
-/* No frame, regex_extra.h must be included always */
-#if (REGEX == 1 || REGEX == 0)  !defined(NO_REGEX_EXTRA_H)
-#include ext/ereg/regex/regex_extra.h
-#endif
http://cvs.php.net/viewvc.cgi/php-src/ext/ereg/regex/utils.h?r1=1.3r2=1.4diff_format=u
Index: php-src/ext/ereg/regex/utils.h
diff -u php-src/ext/ereg/regex/utils.h:1.3 php-src/ext/ereg/regex/utils.h:1.4
--- php-src/ext/ereg/regex/utils.h:1.3  Sat Nov 13 16:51:32 1999
+++ php-src/ext/ereg/regex/utils.h  Mon Jul 16 13:41:12 2007
@@ -1,7 +1,5 @@
 /* utility definitions */
 
-#include regex_extra.h
-
 #ifdef _POSIX2_RE_DUP_MAX
 #defineDUPMAX  _POSIX2_RE_DUP_MAX
 #else
http://cvs.php.net/viewvc.cgi/php-src/sapi/apache/php_apache_http.h?r1=1.17r2=1.18diff_format=u
Index: php-src/sapi/apache/php_apache_http.h
diff -u php-src/sapi/apache/php_apache_http.h:1.17 
php-src/sapi/apache/php_apache_http.h:1.18
--- php-src/sapi/apache/php_apache_http.h:1.17  Sun Jul 15 19:50:07 2007
+++ php-src/sapi/apache/php_apache_http.h   Mon Jul 16 13:41:12 2007
@@ -18,9 +18,7 @@
   +--+
 */
 
-/* $Id: php_apache_http.h,v 1.17 2007/07/15 19:50:07 jani Exp $ */
-
-#define NO_REGEX_EXTRA_H
+/* $Id: php_apache_http.h,v 1.18 2007/07/16 13:41:12 jani Exp $ */
 
 #ifdef WIN32
 #include stddef.h
http://cvs.php.net/viewvc.cgi/php-src/sapi/apache_hooks/php_apache_http.h?r1=1.4r2=1.5diff_format=u
Index: php-src/sapi/apache_hooks/php_apache_http.h
diff -u php-src/sapi/apache_hooks/php_apache_http.h:1.4 
php-src/sapi/apache_hooks/php_apache_http.h:1.5
--- php-src/sapi/apache_hooks/php_apache_http.h:1.4 Sun Jul 15 19:50:07 2007
+++ php-src/sapi/apache_hooks/php_apache_http.h Mon Jul 16 13:41:12 2007
@@ -1,4 +1,3 @@
-#define NO_REGEX_EXTRA_H
 
 #ifdef WIN32
 #include 

[PHP-CVS] cvs: php-src /ext/simplexml/tests bug40451.phpt bug41582.phpt bug41861.phpt bug41867.phpt bug41947.phpt /ext/soap/tests/bugs bug36226-2.phpt /ext/spl/tests bug40872.phpt bug41692.phpt

2007-07-16 Thread Antony Dovgal
tony2001Mon Jul 16 13:46:39 2007 UTC

  Modified files:  
/php-src/ext/simplexml/testsbug40451.phpt bug41582.phpt 
bug41861.phpt bug41867.phpt 
bug41947.phpt 
/php-src/ext/soap/tests/bugsbug36226-2.phpt 
/php-src/ext/spl/tests  bug40872.phpt bug41692.phpt 
  Log:
  add missing skipifs
  
  
http://cvs.php.net/viewvc.cgi/php-src/ext/simplexml/tests/bug40451.phpt?r1=1.2r2=1.3diff_format=u
Index: php-src/ext/simplexml/tests/bug40451.phpt
diff -u php-src/ext/simplexml/tests/bug40451.phpt:1.2 
php-src/ext/simplexml/tests/bug40451.phpt:1.3
--- php-src/ext/simplexml/tests/bug40451.phpt:1.2   Mon Feb 12 21:13:01 2007
+++ php-src/ext/simplexml/tests/bug40451.phpt   Mon Jul 16 13:46:38 2007
@@ -1,5 +1,7 @@
 --TEST--
 Bug #40451 (addAttribute() may crash when used with non-existent child node)
+--SKIPIF--
+?php if (!extension_loaded(simplexml)) die(skip); ?
 --FILE--
 ?php
 
http://cvs.php.net/viewvc.cgi/php-src/ext/simplexml/tests/bug41582.phpt?r1=1.2r2=1.3diff_format=u
Index: php-src/ext/simplexml/tests/bug41582.phpt
diff -u php-src/ext/simplexml/tests/bug41582.phpt:1.2 
php-src/ext/simplexml/tests/bug41582.phpt:1.3
--- php-src/ext/simplexml/tests/bug41582.phpt:1.2   Wed Jun 13 13:38:59 2007
+++ php-src/ext/simplexml/tests/bug41582.phpt   Mon Jul 16 13:46:38 2007
@@ -1,5 +1,7 @@
 --TEST--
 Bug #41582 (SimpleXML crashes when accessing newly created element)
+--SKIPIF--
+?php if (!extension_loaded(simplexml)) die(skip); ?
 --FILE--
 ?php
 
http://cvs.php.net/viewvc.cgi/php-src/ext/simplexml/tests/bug41861.phpt?r1=1.2r2=1.3diff_format=u
Index: php-src/ext/simplexml/tests/bug41861.phpt
diff -u php-src/ext/simplexml/tests/bug41861.phpt:1.2 
php-src/ext/simplexml/tests/bug41861.phpt:1.3
--- php-src/ext/simplexml/tests/bug41861.phpt:1.2   Tue Jul  3 15:02:40 2007
+++ php-src/ext/simplexml/tests/bug41861.phpt   Mon Jul 16 13:46:38 2007
@@ -1,5 +1,7 @@
 --TEST--
 Bug #41861 (getNamespaces() returns the namespaces of a node's siblings)
+--SKIPIF--
+?php if (!extension_loaded(simplexml)) die(skip); ?
 --FILE--
 ?php
 
http://cvs.php.net/viewvc.cgi/php-src/ext/simplexml/tests/bug41867.phpt?r1=1.2r2=1.3diff_format=u
Index: php-src/ext/simplexml/tests/bug41867.phpt
diff -u php-src/ext/simplexml/tests/bug41867.phpt:1.2 
php-src/ext/simplexml/tests/bug41867.phpt:1.3
--- php-src/ext/simplexml/tests/bug41867.phpt:1.2   Mon Jul  2 11:36:28 2007
+++ php-src/ext/simplexml/tests/bug41867.phpt   Mon Jul 16 13:46:38 2007
@@ -1,5 +1,7 @@
 --TEST--
 Bug #41867 (getName is broken)
+--SKIPIF--
+?php if (!extension_loaded(simplexml)) die(skip); ?
 --FILE--
 ?php
 
http://cvs.php.net/viewvc.cgi/php-src/ext/simplexml/tests/bug41947.phpt?r1=1.2r2=1.3diff_format=u
Index: php-src/ext/simplexml/tests/bug41947.phpt
diff -u php-src/ext/simplexml/tests/bug41947.phpt:1.2 
php-src/ext/simplexml/tests/bug41947.phpt:1.3
--- php-src/ext/simplexml/tests/bug41947.phpt:1.2   Tue Jul 10 12:26:37 2007
+++ php-src/ext/simplexml/tests/bug41947.phpt   Mon Jul 16 13:46:38 2007
@@ -1,5 +1,7 @@
 --TEST--
 Bug #41947 (addChild incorrectly registers empty strings as namespaces)
+--SKIPIF--
+?php if (!extension_loaded(simplexml)) die(skip); ?
 --FILE--
 ?php
 $xml = simplexml_load_string('?xml version=1.0 encoding=utf-8?root 
xmlns:myns=http://myns; /');
http://cvs.php.net/viewvc.cgi/php-src/ext/soap/tests/bugs/bug36226-2.phpt?r1=1.2r2=1.3diff_format=u
Index: php-src/ext/soap/tests/bugs/bug36226-2.phpt
diff -u php-src/ext/soap/tests/bugs/bug36226-2.phpt:1.2 
php-src/ext/soap/tests/bugs/bug36226-2.phpt:1.3
--- php-src/ext/soap/tests/bugs/bug36226-2.phpt:1.2 Tue Mar 20 07:51:47 2007
+++ php-src/ext/soap/tests/bugs/bug36226-2.phpt Mon Jul 16 13:46:38 2007
@@ -1,5 +1,7 @@
 --TEST--
 Bug #36226 (Inconsistent handling when passing nillable arrays)
+--SKIPIF--
+?php if (!extension_loaded(soap)) die(skip); ?
 --INI--
 soap.wsdl_cache_enabled=0
 --FILE--
http://cvs.php.net/viewvc.cgi/php-src/ext/spl/tests/bug40872.phpt?r1=1.1r2=1.2diff_format=u
Index: php-src/ext/spl/tests/bug40872.phpt
diff -u php-src/ext/spl/tests/bug40872.phpt:1.1 
php-src/ext/spl/tests/bug40872.phpt:1.2
--- php-src/ext/spl/tests/bug40872.phpt:1.1 Tue Mar 20 20:21:39 2007
+++ php-src/ext/spl/tests/bug40872.phpt Mon Jul 16 13:46:38 2007
@@ -1,5 +1,7 @@
 --TEST--
 Bug #40872 (inconsistency in offsetSet, offsetExists treatment of string 
enclosed integers)
+--SKIPIF--
+?php if (!extension_loaded(spl)) die(skip); ?
 --FILE--
 ?php
class Project {
http://cvs.php.net/viewvc.cgi/php-src/ext/spl/tests/bug41692.phpt?r1=1.1r2=1.2diff_format=u
Index: php-src/ext/spl/tests/bug41692.phpt
diff -u php-src/ext/spl/tests/bug41692.phpt:1.1 
php-src/ext/spl/tests/bug41692.phpt:1.2
--- php-src/ext/spl/tests/bug41692.phpt:1.1 Wed Jun 27 12:17:30 2007
+++ php-src/ext/spl/tests/bug41692.phpt Mon Jul 16 13:46:38 2007
@@ -1,5 +1,7 @@
 --TEST--
 Bug #41692 

[PHP-CVS] cvs: php-src(PHP_5_2) /ext/xmlwriter/tests 010.phpt bug39504.phpt bug41287.phpt bug41326.phpt

2007-07-16 Thread Antony Dovgal
tony2001Mon Jul 16 13:29:47 2007 UTC

  Modified files:  (Branch: PHP_5_2)
/php-src/ext/xmlwriter/tests010.phpt bug39504.phpt bug41287.phpt 
bug41326.phpt 
  Log:
  MFH
  
  
http://cvs.php.net/viewvc.cgi/php-src/ext/xmlwriter/tests/010.phpt?r1=1.1.2.1r2=1.1.2.2diff_format=u
Index: php-src/ext/xmlwriter/tests/010.phpt
diff -u php-src/ext/xmlwriter/tests/010.phpt:1.1.2.1 
php-src/ext/xmlwriter/tests/010.phpt:1.1.2.2
--- php-src/ext/xmlwriter/tests/010.phpt:1.1.2.1Tue Jul 11 16:33:25 2006
+++ php-src/ext/xmlwriter/tests/010.phptMon Jul 16 13:29:47 2007
@@ -1,5 +1,9 @@
 --TEST--
 xmlwriter_start/end_attribute()
+--SKIPIF--
+?php 
+if (!extension_loaded(xmlwriter)) die(skip); 
+?
 --FILE--
 ?php
 
http://cvs.php.net/viewvc.cgi/php-src/ext/xmlwriter/tests/bug39504.phpt?r1=1.2.2.3r2=1.2.2.4diff_format=u
Index: php-src/ext/xmlwriter/tests/bug39504.phpt
diff -u php-src/ext/xmlwriter/tests/bug39504.phpt:1.2.2.3 
php-src/ext/xmlwriter/tests/bug39504.phpt:1.2.2.4
--- php-src/ext/xmlwriter/tests/bug39504.phpt:1.2.2.3   Sat Jan  6 18:03:43 2007
+++ php-src/ext/xmlwriter/tests/bug39504.phpt   Mon Jul 16 13:29:47 2007
@@ -1,5 +1,9 @@
 --TEST--
 Bug #39504 (xmlwriter_write_dtd_entity() creates Attlist tag, not enity)
+--SKIPIF--
+?php 
+if (!extension_loaded(xmlwriter)) die(skip); 
+?
 --FILE--
 ?php
 
http://cvs.php.net/viewvc.cgi/php-src/ext/xmlwriter/tests/bug41287.phpt?r1=1.1.2.3r2=1.1.2.4diff_format=u
Index: php-src/ext/xmlwriter/tests/bug41287.phpt
diff -u php-src/ext/xmlwriter/tests/bug41287.phpt:1.1.2.3 
php-src/ext/xmlwriter/tests/bug41287.phpt:1.1.2.4
--- php-src/ext/xmlwriter/tests/bug41287.phpt:1.1.2.3   Mon May 14 09:23:49 2007
+++ php-src/ext/xmlwriter/tests/bug41287.phpt   Mon Jul 16 13:29:47 2007
@@ -1,5 +1,9 @@
 --TEST--
 Bug #41287 (Namespace functions don't allow xmlns defintion to be optional)
+--SKIPIF--
+?php 
+if (!extension_loaded(xmlwriter)) die(skip); 
+?
 --FILE--
 ?php
 
http://cvs.php.net/viewvc.cgi/php-src/ext/xmlwriter/tests/bug41326.phpt?r1=1.1.2.3r2=1.1.2.4diff_format=u
Index: php-src/ext/xmlwriter/tests/bug41326.phpt
diff -u php-src/ext/xmlwriter/tests/bug41326.phpt:1.1.2.3 
php-src/ext/xmlwriter/tests/bug41326.phpt:1.1.2.4
--- php-src/ext/xmlwriter/tests/bug41326.phpt:1.1.2.3   Mon May 14 09:23:49 2007
+++ php-src/ext/xmlwriter/tests/bug41326.phpt   Mon Jul 16 13:29:47 2007
@@ -1,5 +1,9 @@
 --TEST--
 Bug #41287 (Writing empty tags with Xmlwriter::WriteElement[ns])
+--SKIPIF--
+?php 
+if (!extension_loaded(xmlwriter)) die(skip); 
+?
 --FILE--
 ?php
 $xml = new XmlWriter();

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



[PHP-CVS] cvs: php-src /ext/ereg config.w32

2007-07-16 Thread Jani Taskinen
janiMon Jul 16 13:51:41 2007 UTC

  Modified files:  
/php-src/ext/ereg   config.w32 
  Log:
  - Fix win32 build (I guess..:)
  
http://cvs.php.net/viewvc.cgi/php-src/ext/ereg/config.w32?r1=1.1r2=1.2diff_format=u
Index: php-src/ext/ereg/config.w32
diff -u php-src/ext/ereg/config.w32:1.1 php-src/ext/ereg/config.w32:1.2
--- php-src/ext/ereg/config.w32:1.1 Sun Jul 15 19:50:06 2007
+++ php-src/ext/ereg/config.w32 Mon Jul 16 13:51:41 2007
@@ -1,7 +1,7 @@
-// $Id: config.w32,v 1.1 2007/07/15 19:50:06 jani Exp $
+// $Id: config.w32,v 1.2 2007/07/16 13:51:41 jani Exp $
 // vim:ft=javascript
 
-EXTENSION(ereg, ereg.c, false /* never shared */, -Iext/ereg/regex);
+EXTENSION(ereg, ereg.c, false /* never shared */, -Dregexec=php_regexec 
-Dregerror=php_regerror -Dregfree=php_regfree -Dregcomp=php_regcomp 
-Iext/ereg/regex);
 ADD_SOURCES(ext/ereg/regex, regcomp.c regexec.c regerror.c regfree.c, 
ereg);
 AC_DEFINE('REGEX', 1, 'Bundled regex');
 AC_DEFINE('HSREGEX', 1, 'Bundled regex');

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



[PHP-CVS] cvs: php-src /ext/xmlwriter/tests 010.phpt bug39504.phpt bug41287.phpt bug41326.phpt

2007-07-16 Thread Antony Dovgal
tony2001Mon Jul 16 13:29:41 2007 UTC

  Modified files:  
/php-src/ext/xmlwriter/tests010.phpt bug39504.phpt bug41287.phpt 
bug41326.phpt 
  Log:
  add missing skipif sections
  
  
http://cvs.php.net/viewvc.cgi/php-src/ext/xmlwriter/tests/010.phpt?r1=1.2r2=1.3diff_format=u
Index: php-src/ext/xmlwriter/tests/010.phpt
diff -u php-src/ext/xmlwriter/tests/010.phpt:1.2 
php-src/ext/xmlwriter/tests/010.phpt:1.3
--- php-src/ext/xmlwriter/tests/010.phpt:1.2Wed Aug  9 18:37:39 2006
+++ php-src/ext/xmlwriter/tests/010.phptMon Jul 16 13:29:41 2007
@@ -1,5 +1,9 @@
 --TEST--
 xmlwriter_start/end_attribute()
+--SKIPIF--
+?php 
+if (!extension_loaded(xmlwriter)) die(skip); 
+?
 --FILE--
 ?php
 
http://cvs.php.net/viewvc.cgi/php-src/ext/xmlwriter/tests/bug39504.phpt?r1=1.3r2=1.4diff_format=u
Index: php-src/ext/xmlwriter/tests/bug39504.phpt
diff -u php-src/ext/xmlwriter/tests/bug39504.phpt:1.3 
php-src/ext/xmlwriter/tests/bug39504.phpt:1.4
--- php-src/ext/xmlwriter/tests/bug39504.phpt:1.3   Sat Jan  6 18:03:15 2007
+++ php-src/ext/xmlwriter/tests/bug39504.phpt   Mon Jul 16 13:29:41 2007
@@ -1,5 +1,9 @@
 --TEST--
 Bug #39504 (xmlwriter_write_dtd_entity() creates Attlist tag, not enity)
+--SKIPIF--
+?php 
+if (!extension_loaded(xmlwriter)) die(skip); 
+?
 --FILE--
 ?php
 
http://cvs.php.net/viewvc.cgi/php-src/ext/xmlwriter/tests/bug41287.phpt?r1=1.4r2=1.5diff_format=u
Index: php-src/ext/xmlwriter/tests/bug41287.phpt
diff -u php-src/ext/xmlwriter/tests/bug41287.phpt:1.4 
php-src/ext/xmlwriter/tests/bug41287.phpt:1.5
--- php-src/ext/xmlwriter/tests/bug41287.phpt:1.4   Mon May 14 09:22:44 2007
+++ php-src/ext/xmlwriter/tests/bug41287.phpt   Mon Jul 16 13:29:41 2007
@@ -1,5 +1,9 @@
 --TEST--
 Bug #41287 (Namespace functions don't allow xmlns defintion to be optional)
+--SKIPIF--
+?php 
+if (!extension_loaded(xmlwriter)) die(skip); 
+?
 --FILE--
 ?php
 
http://cvs.php.net/viewvc.cgi/php-src/ext/xmlwriter/tests/bug41326.phpt?r1=1.2r2=1.3diff_format=u
Index: php-src/ext/xmlwriter/tests/bug41326.phpt
diff -u php-src/ext/xmlwriter/tests/bug41326.phpt:1.2 
php-src/ext/xmlwriter/tests/bug41326.phpt:1.3
--- php-src/ext/xmlwriter/tests/bug41326.phpt:1.2   Mon May 14 09:22:44 2007
+++ php-src/ext/xmlwriter/tests/bug41326.phpt   Mon Jul 16 13:29:41 2007
@@ -1,5 +1,9 @@
 --TEST--
 Bug #41287 (Writing empty tags with Xmlwriter::WriteElement[ns])
+--SKIPIF--
+?php 
+if (!extension_loaded(xmlwriter)) die(skip); 
+?
 --FILE--
 ?php
 $xml = new XmlWriter();

-- 
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 disk_free_space_error-win32.phpt disk_free_space_error.phpt disk_total_space_error-win32.phpt disk_total_space_error.phpt

2007-07-16 Thread Raghubansh Kumar
kraghubaMon Jul 16 17:34:45 2007 UTC

  Added files: (Branch: PHP_5_2)
/php-src/ext/standard/tests/filedisk_total_space_error-win32.phpt 
disk_total_space_error.phpt 
disk_free_space_error-win32.phpt 
disk_free_space_error.phpt 
  Log:
  New testcases 
  

http://cvs.php.net/viewvc.cgi/php-src/ext/standard/tests/file/disk_total_space_error-win32.phpt?view=markuprev=1.1
Index: php-src/ext/standard/tests/file/disk_total_space_error-win32.phpt
+++ php-src/ext/standard/tests/file/disk_total_space_error-win32.phpt

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

http://cvs.php.net/viewvc.cgi/php-src/ext/standard/tests/file/disk_free_space_error-win32.phpt?view=markuprev=1.1
Index: php-src/ext/standard/tests/file/disk_free_space_error-win32.phpt
+++ php-src/ext/standard/tests/file/disk_free_space_error-win32.phpt

http://cvs.php.net/viewvc.cgi/php-src/ext/standard/tests/file/disk_free_space_error.phpt?view=markuprev=1.1
Index: php-src/ext/standard/tests/file/disk_free_space_error.phpt
+++ php-src/ext/standard/tests/file/disk_free_space_error.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/standard/tests/file symlink_link_linkinfo_is_link_error1.phpt symlink_link_linkinfo_is_link_error2.phpt

2007-07-16 Thread Raghubansh Kumar
kraghubaMon Jul 16 17:55:39 2007 UTC

  Modified files:  (Branch: PHP_5_2)
/php-src/ext/standard/tests/file

symlink_link_linkinfo_is_link_error1.phpt 

symlink_link_linkinfo_is_link_error2.phpt 
  Log:
  fix tests
  
http://cvs.php.net/viewvc.cgi/php-src/ext/standard/tests/file/symlink_link_linkinfo_is_link_error1.phpt?r1=1.1.2.2r2=1.1.2.3diff_format=u
Index: php-src/ext/standard/tests/file/symlink_link_linkinfo_is_link_error1.phpt
diff -u 
php-src/ext/standard/tests/file/symlink_link_linkinfo_is_link_error1.phpt:1.1.2.2
 
php-src/ext/standard/tests/file/symlink_link_linkinfo_is_link_error1.phpt:1.1.2.3
--- 
php-src/ext/standard/tests/file/symlink_link_linkinfo_is_link_error1.phpt:1.1.2.2
   Tue Jul 10 13:21:11 2007
+++ php-src/ext/standard/tests/file/symlink_link_linkinfo_is_link_error1.phpt   
Mon Jul 16 17:55:39 2007
@@ -87,13 +87,13 @@
 Warning: symlink(): %s in %s on line %d
 bool(false)
 
-Warning: symlink(): No such file or directory in %s on line %d
+Warning: symlink(): %s in %s on line %d
 bool(false)
 
-Warning: symlink(): No such file or directory in %s on line %d
+Warning: symlink(): %s in %s on line %d
 bool(false)
 
-Warning: symlink(): No such file or directory in %s on line %d
+Warning: symlink(): %s in %s on line %d
 bool(false)
 
 *** Testing linkinfo() for error conditions ***
@@ -104,12 +104,12 @@
 Warning: Wrong parameter count for linkinfo() in %s on line %d
 NULL
 
-Warning: linkinfo(): No such file or directory in %s on line %d
+Warning: linkinfo(): %s in %s on line %d
 int(-1)
 
-Warning: linkinfo(): No such file or directory in %s on line %d
+Warning: linkinfo(): %s in %s on line %d
 int(-1)
 
-Warning: linkinfo(): No such file or directory in %s on line %d
+Warning: linkinfo(): %s in %s on line %d
 int(-1)
 Done
http://cvs.php.net/viewvc.cgi/php-src/ext/standard/tests/file/symlink_link_linkinfo_is_link_error2.phpt?r1=1.1.2.1r2=1.1.2.2diff_format=u
Index: php-src/ext/standard/tests/file/symlink_link_linkinfo_is_link_error2.phpt
diff -u 
php-src/ext/standard/tests/file/symlink_link_linkinfo_is_link_error2.phpt:1.1.2.1
 
php-src/ext/standard/tests/file/symlink_link_linkinfo_is_link_error2.phpt:1.1.2.2
--- 
php-src/ext/standard/tests/file/symlink_link_linkinfo_is_link_error2.phpt:1.1.2.1
   Thu Jul  5 18:53:33 2007
+++ php-src/ext/standard/tests/file/symlink_link_linkinfo_is_link_error2.phpt   
Mon Jul 16 17:55:39 2007
@@ -75,22 +75,22 @@
 Warning: Wrong parameter count for link() in %s on line %d
 NULL
 
-Warning: link(): No such file or directory in %s on line %d
+Warning: link(): %s in %s on line %d
 bool(false)
 
-Warning: link(): No such file or directory in %s on line %d
+Warning: link(): %s in %s on line %d
 bool(false)
 
-Warning: link(): No such file or directory in %s on line %d
+Warning: link(): %s in %s on line %d
 bool(false)
 
-Warning: link(): No such file or directory in %s on line %d
+Warning: link(): %s in %s on line %d
 bool(false)
 
-Warning: link(): No such file or directory in %s on line %d
+Warning: link(): %s in %s on line %d
 bool(false)
 
-Warning: link(): No such file or directory in %s on line %d
+Warning: link(): %s in %s on line %d
 bool(false)
 
 *** Testing is_link() for error conditions ***

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

2007-07-16 Thread Ilia Alshanetsky
iliaa   Mon Jul 16 18:00:19 2007 UTC

  Modified files:  (Branch: PHP_5_2)
/php-src/ext/pdopdo_dbh.c 
  Log:
  Fixed a possible crash inside the constructor
  
http://cvs.php.net/viewvc.cgi/php-src/ext/pdo/pdo_dbh.c?r1=1.82.2.31.2.14r2=1.82.2.31.2.15diff_format=u
Index: php-src/ext/pdo/pdo_dbh.c
diff -u php-src/ext/pdo/pdo_dbh.c:1.82.2.31.2.14 
php-src/ext/pdo/pdo_dbh.c:1.82.2.31.2.15
--- php-src/ext/pdo/pdo_dbh.c:1.82.2.31.2.14Thu Jun 28 19:22:52 2007
+++ php-src/ext/pdo/pdo_dbh.c   Mon Jul 16 18:00:18 2007
@@ -18,7 +18,7 @@
   +--+
 */
 
-/* $Id: pdo_dbh.c,v 1.82.2.31.2.14 2007/06/28 19:22:52 iliaa Exp $ */
+/* $Id: pdo_dbh.c,v 1.82.2.31.2.15 2007/07/16 18:00:18 iliaa Exp $ */
 
 /* The PDO Database Handle Class */
 
@@ -364,23 +364,9 @@
php_error_docref(NULL TSRMLS_CC, E_ERROR, out of memory);
}
 
-   if (options) {
-   zval **attr_value;
-   char *str_key;
-   long long_key;
-   
-   zend_hash_internal_pointer_reset(Z_ARRVAL_P(options));
-   while (SUCCESS == 
zend_hash_get_current_data(Z_ARRVAL_P(options), (void**)attr_value) 
-HASH_KEY_IS_LONG == 
zend_hash_get_current_key(Z_ARRVAL_P(options), str_key, long_key, 0)) {
-   
-   pdo_dbh_attribute_set(dbh, long_key, *attr_value 
TSRMLS_CC);
-   zend_hash_move_forward(Z_ARRVAL_P(options));
-   }
-   }
-
if (!call_factory) {
/* we got a persistent guy from our cache */
-   return;
+   goto options;
}
 
if (driver-db_handle_factory(dbh, options TSRMLS_CC)) {
@@ -404,8 +390,22 @@
}
 
dbh-driver = driver;
+options:
+   if (options) {
+   zval **attr_value;
+   char *str_key;
+   long long_key;
+   
+   zend_hash_internal_pointer_reset(Z_ARRVAL_P(options));
+   while (SUCCESS == 
zend_hash_get_current_data(Z_ARRVAL_P(options), (void**)attr_value) 
+HASH_KEY_IS_LONG == 
zend_hash_get_current_key(Z_ARRVAL_P(options), str_key, long_key, 0)) {
+   
+   pdo_dbh_attribute_set(dbh, long_key, 
*attr_value TSRMLS_CC);
+   zend_hash_move_forward(Z_ARRVAL_P(options));
+   }
+   }
 
-   return; 
+   return;
}
 
/* the connection failed; things will tidy up in free_storage */

-- 
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 symlink_link_linkinfo_is_link_error1.phpt symlink_link_linkinfo_is_link_error2.phpt

2007-07-16 Thread Raghubansh Kumar
kraghubaMon Jul 16 18:02:11 2007 UTC

  Modified files:  
/php-src/ext/standard/tests/file

symlink_link_linkinfo_is_link_error2.phpt 

symlink_link_linkinfo_is_link_error1.phpt 
  Log:
  fix tests
  
http://cvs.php.net/viewvc.cgi/php-src/ext/standard/tests/file/symlink_link_linkinfo_is_link_error2.phpt?r1=1.2r2=1.3diff_format=u
Index: php-src/ext/standard/tests/file/symlink_link_linkinfo_is_link_error2.phpt
diff -u 
php-src/ext/standard/tests/file/symlink_link_linkinfo_is_link_error2.phpt:1.2 
php-src/ext/standard/tests/file/symlink_link_linkinfo_is_link_error2.phpt:1.3
--- 
php-src/ext/standard/tests/file/symlink_link_linkinfo_is_link_error2.phpt:1.2   
Thu Jul  5 18:59:20 2007
+++ php-src/ext/standard/tests/file/symlink_link_linkinfo_is_link_error2.phpt   
Mon Jul 16 18:02:11 2007
@@ -75,22 +75,22 @@
 Warning: link() expects exactly 2 parameters, 3 given in %s on line %d
 NULL
 
-Warning: link(): No such file or directory in %s on line %d
+Warning: link(): %s in %s on line %d
 bool(false)
 
-Warning: link(): No such file or directory in %s on line %d
+Warning: link(): %s in %s on line %d
 bool(false)
 
-Warning: link(): No such file or directory in %s on line %d
+Warning: link(): %s in %s on line %d
 bool(false)
 
-Warning: link(): No such file or directory in %s on line %d
+Warning: link(): %s in %s on line %d
 bool(false)
 
-Warning: link(): No such file or directory in %s on line %d
+Warning: link(): %s in %s on line %d
 bool(false)
 
-Warning: link(): No such file or directory in %s on line %d
+Warning: link(): %s in %s on line %d
 bool(false)
 
 *** Testing is_link() for error conditions ***
@@ -114,22 +114,22 @@
 Warning: link() expects exactly 2 parameters, 3 given in %s on line %d
 NULL
 
-Warning: link(): No such file or directory in %s on line %d
+Warning: link(): %s in %s on line %d
 bool(false)
 
-Warning: link(): No such file or directory in %s on line %d
+Warning: link(): %s in %s on line %d
 bool(false)
 
-Warning: link(): No such file or directory in %s on line %d
+Warning: link(): %s in %s on line %d
 bool(false)
 
-Warning: link(): No such file or directory in %s on line %d
+Warning: link(): %s in %s on line %d
 bool(false)
 
-Warning: link(): No such file or directory in %s on line %d
+Warning: link(): %s in %s on line %d
 bool(false)
 
-Warning: link(): No such file or directory in %s on line %d
+Warning: link(): %s in %s on line %d
 bool(false)
 
 *** Testing is_link() for error conditions ***
http://cvs.php.net/viewvc.cgi/php-src/ext/standard/tests/file/symlink_link_linkinfo_is_link_error1.phpt?r1=1.3r2=1.4diff_format=u
Index: php-src/ext/standard/tests/file/symlink_link_linkinfo_is_link_error1.phpt
diff -u 
php-src/ext/standard/tests/file/symlink_link_linkinfo_is_link_error1.phpt:1.3 
php-src/ext/standard/tests/file/symlink_link_linkinfo_is_link_error1.phpt:1.4
--- 
php-src/ext/standard/tests/file/symlink_link_linkinfo_is_link_error1.phpt:1.3   
Tue Jul 10 13:21:31 2007
+++ php-src/ext/standard/tests/file/symlink_link_linkinfo_is_link_error1.phpt   
Mon Jul 16 18:02:11 2007
@@ -87,13 +87,13 @@
 Warning: symlink(): %s in %s on line %d
 bool(false)
 
-Warning: symlink(): No such file or directory in %s on line %d
+Warning: symlink(): %s in %s on line %d
 bool(false)
 
-Warning: symlink(): No such file or directory in %s on line %d
+Warning: symlink(): %s in %s on line %d
 bool(false)
 
-Warning: symlink(): No such file or directory in %s on line %d
+Warning: symlink(): %s in %s on line %d
 bool(false)
 
 *** Testing linkinfo() for error conditions ***
@@ -104,13 +104,13 @@
 Warning: linkinfo() expects exactly 1 parameter, 2 given in %s on line %d
 NULL
 
-Warning: linkinfo(): No such file or directory in %s on line %d
+Warning: linkinfo(): %s in %s on line %d
 int(-1)
 
-Warning: linkinfo(): No such file or directory in %s on line %d
+Warning: linkinfo(): %s in %s on line %d
 int(-1)
 
-Warning: linkinfo(): No such file or directory in %s on line %d
+Warning: linkinfo(): %s in %s on line %d
 int(-1)
 Done
 --UEXPECTF--
@@ -131,13 +131,13 @@
 Warning: symlink(): %s in %s on line %d
 bool(false)
 
-Warning: symlink(): No such file or directory in %s on line %d
+Warning: symlink(): %s in %s on line %d
 bool(false)
 
-Warning: symlink(): No such file or directory in %s on line %d
+Warning: symlink(): %s in %s on line %d
 bool(false)
 
-Warning: symlink(): No such file or directory in %s on line %d
+Warning: symlink(): %s in %s on line %d
 bool(false)
 
 *** Testing linkinfo() for error conditions ***
@@ -148,12 +148,12 @@
 Warning: linkinfo() expects exactly 1 parameter, 2 given in %s on line %d
 NULL
 
-Warning: linkinfo(): No such file or directory in %s on line %d
+Warning: linkinfo(): %s in %s on line %d
 int(-1)
 
-Warning: linkinfo(): No such file or directory in %s on line %d
+Warning: linkinfo(): %s in %s on line %d
 int(-1)
 
-Warning: linkinfo(): No such 

[PHP-CVS] cvs: php-src /ext/standard/tests/file disk_free_space_error-win32.phpt disk_free_space_error.phpt disk_total_space_error-win32.phpt disk_total_space_error.phpt

2007-07-16 Thread Raghubansh Kumar
kraghubaMon Jul 16 17:36:33 2007 UTC

  Modified files:  
/php-src/ext/standard/tests/filedisk_free_space_error-win32.phpt 
disk_free_space_error.phpt 
disk_total_space_error-win32.phpt 
disk_total_space_error.phpt 
  Log:
  New testcases 
  http://cvs.php.net/viewvc.cgi/php-src/ext/standard/tests/file/disk_free_space_error-win32.phpt?r1=1.1r2=1.2diff_format=u
Index: php-src/ext/standard/tests/file/disk_free_space_error-win32.phpt
diff -u /dev/null 
php-src/ext/standard/tests/file/disk_free_space_error-win32.phpt:1.2
--- /dev/null   Mon Jul 16 17:36:33 2007
+++ php-src/ext/standard/tests/file/disk_free_space_error-win32.phptMon Jul 
16 17:36:33 2007
@@ -0,0 +1,109 @@
+--TEST--
+Test disk_free_space and its alias diskfreespace() functions : error conditions
+--SKIPIF--
+?php
+if(substr(PHP_OS, 0, 3) != 'WIN' )
+  die(skip Valid only for Windows);
+?
+--FILE--
+?php
+/*
+ *  Prototype: float disk_free_space( string directory )
+ *  Description: Given a string containing a directory, this function will
+ *   return the number of bytes available on the corresponding 
+ *   filesystem or disk partition
+ */
+
+echo *** Testing error conditions ***\n;
+$file_path = dirname(__FILE__);
+var_dump( disk_free_space() ); // Zero Arguments
+var_dump( diskfreespace() );
+
+var_dump( disk_free_space( $file_path, extra argument) ); // More than valid 
number of arguments
+var_dump( diskfreespace( $file_path, extra argument) );
+
+
+var_dump( disk_free_space( $file_path./dir1 )); // Invalid directory
+var_dump( diskfreespace( $file_path./dir1 ));
+
+$fh = fopen( $file_path./disk_free_space.tmp, w );
+fwrite( $fh,  Garbage data for the temporary file );
+var_dump( disk_free_space( $file_path./disk_free_space.tmp )); // file input 
instead of directory
+var_dump( diskfreespace( $file_path./disk_free_space.tmp ));
+fclose($fh);
+
+echo\n-- Done --;
+?
+--CLEAN--
+?php
+$file_path = dirname(__FILE__);
+unlink($file_path./disk_free_space.tmp);
+
+?
+--EXPECTF--
+*** Testing error conditions ***
+
+Warning: disk_free_space() expects exactly 1 parameter, 0 given in %s on line 
%d
+NULL
+
+Warning: diskfreespace() expects exactly 1 parameter, 0 given in %s on line %d
+NULL
+
+Warning: disk_free_space() expects exactly 1 parameter, 2 given in %s on line 
%d
+NULL
+
+Warning: diskfreespace() expects exactly 1 parameter, 2 given in %s on line %d
+NULL
+
+Warning: disk_free_space(): The system cannot find the path specified.
+ in %s on line %d
+bool(false)
+
+Warning: diskfreespace(): The system cannot find the path specified.
+ in %s on line %d
+bool(false)
+
+Warning: disk_free_space(): The directory name is invalid.
+ in %s on line %d
+bool(false)
+
+Warning: diskfreespace(): The directory name is invalid.
+ in %s on line %d
+bool(false)
+
+-- Done --
+
+--UEXPECTF--
+*** Testing error conditions ***
+
+Warning: disk_free_space() expects exactly 1 parameter, 0 given in %s on line 
%d
+NULL
+
+Warning: diskfreespace() expects exactly 1 parameter, 0 given in %s on line %d
+NULL
+
+Warning: disk_free_space() expects exactly 1 parameter, 2 given in %s on line 
%d
+NULL
+
+Warning: diskfreespace() expects exactly 1 parameter, 2 given in %s on line %d
+NULL
+
+Warning: disk_free_space(): The system cannot find the path specified.
+ in %s on line %d
+bool(false)
+
+Warning: diskfreespace(): The system cannot find the path specified.
+ in %s on line %d
+bool(false)
+
+Notice: fwrite(): 36 character unicode buffer downcoded for binary stream 
runtime_encoding in %s on line %d
+
+Warning: disk_free_space(): The directory name is invalid.
+ in %s on line %d
+bool(false)
+
+Warning: diskfreespace(): The directory name is invalid.
+ in %s on line %d
+bool(false)
+
+-- Done --
http://cvs.php.net/viewvc.cgi/php-src/ext/standard/tests/file/disk_free_space_error.phpt?r1=1.1r2=1.2diff_format=u
Index: php-src/ext/standard/tests/file/disk_free_space_error.phpt
diff -u /dev/null php-src/ext/standard/tests/file/disk_free_space_error.phpt:1.2
--- /dev/null   Mon Jul 16 17:36:33 2007
+++ php-src/ext/standard/tests/file/disk_free_space_error.phpt  Mon Jul 16 
17:36:33 2007
@@ -0,0 +1,91 @@
+--TEST--
+Test disk_free_space and its alias diskfreespace() functions : error 
conditions.
+--SKIPIF--
+?php
+if(substr(PHP_OS, 0, 3) == 'WIN')
+  die(skip Not valid on Windows);
+?
+--FILE--
+?php
+/*
+ *  Prototype: float disk_free_space( string directory )
+ *  Description: Given a string containing a directory, this function will 
+ *   return the number of bytes available on the corresponding 
+ *   filesystem or disk partition
+ */
+
+echo *** Testing error conditions ***\n;
+$file_path = dirname(__FILE__);
+var_dump( disk_free_space() ); // Zero Arguments
+var_dump( diskfreespace() );
+
+var_dump( disk_free_space( $file_path, extra argument) ); // More than 

[PHP-CVS] cvs: php-src /sapi/apache config.w32

2007-07-16 Thread Antony Dovgal
tony2001Mon Jul 16 19:02:43 2007 UTC

  Modified files:  
/php-src/sapi/apacheconfig.w32 
  Log:
  fix win32 build
  
  
http://cvs.php.net/viewvc.cgi/php-src/sapi/apache/config.w32?r1=1.7r2=1.8diff_format=u
Index: php-src/sapi/apache/config.w32
diff -u php-src/sapi/apache/config.w32:1.7 php-src/sapi/apache/config.w32:1.8
--- php-src/sapi/apache/config.w32:1.7  Sat Jan 17 13:00:04 2004
+++ php-src/sapi/apache/config.w32  Mon Jul 16 19:02:43 2007
@@ -1,5 +1,5 @@
 // vim:ft=javascript
-// $Id: config.w32,v 1.7 2004/01/17 13:00:04 sniper Exp $
+// $Id: config.w32,v 1.8 2007/07/16 19:02:43 tony2001 Exp $
 
 ARG_ENABLE('apache', 'Build Apache 1.3.x version of PHP', 'no');
 
@@ -15,7 +15,7 @@
';..\\php_build\\apache\\src\\corer')) {
// We need to play tricks to get our readdir.h used by apache
// headers
-   SAPI('apache', 'mod_php5.c sapi_apache.c php_apache.c',
+   SAPI('apache', 'mod_php.c sapi_apache.c php_apache.c',
'php' + PHP_VERSION + 'apache.dll',
'/D APACHEPHP5_EXPORTS /D APACHE_READDIR_H /I 
win32');
} else {

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



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

2007-07-16 Thread Antony Dovgal
tony2001Mon Jul 16 19:12:47 2007 UTC

  Modified files:  
/php-src/ext/oci8   oci8.c 
  Log:
  fix win32 build
  
  
http://cvs.php.net/viewvc.cgi/php-src/ext/oci8/oci8.c?r1=1.331r2=1.332diff_format=u
Index: php-src/ext/oci8/oci8.c
diff -u php-src/ext/oci8/oci8.c:1.331 php-src/ext/oci8/oci8.c:1.332
--- php-src/ext/oci8/oci8.c:1.331   Fri Jun  8 08:44:25 2007
+++ php-src/ext/oci8/oci8.c Mon Jul 16 19:12:47 2007
@@ -26,7 +26,7 @@
+--+
 */
 
-/* $Id: oci8.c,v 1.331 2007/06/08 08:44:25 tony2001 Exp $ */
+/* $Id: oci8.c,v 1.332 2007/07/16 19:12:47 tony2001 Exp $ */
 /* TODO
  *
  * file://localhost/www/docs/oci10/ociaahan.htm#423823 - implement lob_empty() 
with OCI_ATTR_LOBEMPTY
@@ -674,7 +674,7 @@
php_info_print_table_start();
php_info_print_table_row(2, OCI8 Support, enabled);
php_info_print_table_row(2, Version, 1.2.2);
-   php_info_print_table_row(2, Revision, $Revision: 1.331 $);
+   php_info_print_table_row(2, Revision, $Revision: 1.332 $);
 
snprintf(buf, sizeof(buf), %ld, OCI_G(num_persistent));
php_info_print_table_row(2, Active Persistent Connections, buf);
@@ -1636,7 +1636,7 @@
php_oci_descriptor *descriptor;
ub4 lob_length;
int column_size;
-   zstr lob_buffer, zstr_data = (zstr)column-data;
+   zstr lob_buffer, zstr_data = ZSTR(column-data);

if (column-indicator == -1) { /* column is NULL */ 
ZVAL_NULL(value); 

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



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

2007-07-16 Thread Antony Dovgal
tony2001Mon Jul 16 19:16:00 2007 UTC

  Modified files:  
/php-src/ext/oci8   oci8_statement.c 
  Log:
  more build fixes
  
  
http://cvs.php.net/viewvc.cgi/php-src/ext/oci8/oci8_statement.c?r1=1.46r2=1.47diff_format=u
Index: php-src/ext/oci8/oci8_statement.c
diff -u php-src/ext/oci8/oci8_statement.c:1.46 
php-src/ext/oci8/oci8_statement.c:1.47
--- php-src/ext/oci8/oci8_statement.c:1.46  Fri Jun  8 08:44:26 2007
+++ php-src/ext/oci8/oci8_statement.c   Mon Jul 16 19:16:00 2007
@@ -25,7 +25,7 @@
+--+
 */
 
-/* $Id: oci8_statement.c,v 1.46 2007/06/08 08:44:26 tony2001 Exp $ */
+/* $Id: oci8_statement.c,v 1.47 2007/07/16 19:16:00 tony2001 Exp $ */
 
 
 #ifdef HAVE_CONFIG_H
@@ -234,7 +234,7 @@
(void *) 
column-oci_define,
OCI_HTYPE_DEFINE,
statement-err,
-   ((void*)zstr_data.s) + 
column-retlen4,
+   ((char *)zstr_data.s) + 
column-retlen4,
(column-cb_retlen),
piecep,
column-indicator,

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



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

2007-07-16 Thread Antony Dovgal
tony2001Mon Jul 16 19:36:28 2007 UTC

  Modified files:  
/php-src/ext/pdo_dblib  pdo_dblib.c 
  Log:
  fix typo
  
  
http://cvs.php.net/viewvc.cgi/php-src/ext/pdo_dblib/pdo_dblib.c?r1=1.15r2=1.16diff_format=u
Index: php-src/ext/pdo_dblib/pdo_dblib.c
diff -u php-src/ext/pdo_dblib/pdo_dblib.c:1.15 
php-src/ext/pdo_dblib/pdo_dblib.c:1.16
--- php-src/ext/pdo_dblib/pdo_dblib.c:1.15  Mon Jan  1 09:29:27 2007
+++ php-src/ext/pdo_dblib/pdo_dblib.c   Mon Jul 16 19:36:28 2007
@@ -17,7 +17,7 @@
   +--+
 */
 
-/* $Id: pdo_dblib.c,v 1.15 2007/01/01 09:29:27 sebastian Exp $ */
+/* $Id: pdo_dblib.c,v 1.16 2007/07/16 19:36:28 tony2001 Exp $ */
 
 #ifdef HAVE_CONFIG_H
 # include config.h
@@ -67,7 +67,7 @@
PHP_RSHUTDOWN(pdo_dblib),
PHP_MINFO(pdo_dblib),
0.9,
-   PHP_MODULE_GLOBASLS(dblib),
+   PHP_MODULE_GLOBALS(dblib),
PHP_GINIT(dblib),
NULL,
NULL,

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



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

2007-07-16 Thread Antony Dovgal
tony2001Mon Jul 16 20:29:21 2007 UTC

  Modified files:  (Branch: PHP_5_2)
/php-src/ext/standard   dir.c 
  Log:
  initialize glob struct
  
  
http://cvs.php.net/viewvc.cgi/php-src/ext/standard/dir.c?r1=1.147.2.3.2.8r2=1.147.2.3.2.9diff_format=u
Index: php-src/ext/standard/dir.c
diff -u php-src/ext/standard/dir.c:1.147.2.3.2.8 
php-src/ext/standard/dir.c:1.147.2.3.2.9
--- php-src/ext/standard/dir.c:1.147.2.3.2.8Mon Jun 25 08:40:20 2007
+++ php-src/ext/standard/dir.c  Mon Jul 16 20:29:21 2007
@@ -16,7 +16,7 @@
+--+
  */
 
-/* $Id: dir.c,v 1.147.2.3.2.8 2007/06/25 08:40:20 dmitry Exp $ */
+/* $Id: dir.c,v 1.147.2.3.2.9 2007/07/16 20:29:21 tony2001 Exp $ */
 
 /* {{{ includes/startup/misc */
 
@@ -412,6 +412,7 @@
efree(basename);
}
 
+   memset(globbuf, 0, sizeof(glob_t));
globbuf.gl_offs = 0;
if (0 != (ret = glob(pattern, flags  GLOB_FLAGMASK, NULL, globbuf))) {
 #ifdef GLOB_NOMATCH

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



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

2007-07-16 Thread Antony Dovgal
tony2001Mon Jul 16 20:29:37 2007 UTC

  Modified files:  
/php-src/ext/standard   dir.c 
  Log:
  MFB: initialize glob struct
  
  
http://cvs.php.net/viewvc.cgi/php-src/ext/standard/dir.c?r1=1.166r2=1.167diff_format=u
Index: php-src/ext/standard/dir.c
diff -u php-src/ext/standard/dir.c:1.166 php-src/ext/standard/dir.c:1.167
--- php-src/ext/standard/dir.c:1.166Tue Jun 26 12:14:24 2007
+++ php-src/ext/standard/dir.c  Mon Jul 16 20:29:37 2007
@@ -16,7 +16,7 @@
+--+
  */
 
-/* $Id: dir.c,v 1.166 2007/06/26 12:14:24 tony2001 Exp $ */
+/* $Id: dir.c,v 1.167 2007/07/16 20:29:37 tony2001 Exp $ */
 
 /* {{{ includes/startup/misc */
 
@@ -435,6 +435,7 @@
efree(basename);
}
 
+   memset(globbuf, 0, sizeof(glob_t));
globbuf.gl_offs = 0;
if (0 != (ret = glob(pattern, flags  GLOB_FLAGMASK, NULL, globbuf))) {
 #ifdef GLOB_NOMATCH

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



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

2007-07-16 Thread Antony Dovgal
tony2001Mon Jul 16 20:30:27 2007 UTC

  Modified files:  (Branch: PHP_4_4)
/php-src/ext/standard   dir.c 
  Log:
  MF52: initialize glob struct
  
  
http://cvs.php.net/viewvc.cgi/php-src/ext/standard/dir.c?r1=1.109.2.18.2.7r2=1.109.2.18.2.8diff_format=u
Index: php-src/ext/standard/dir.c
diff -u php-src/ext/standard/dir.c:1.109.2.18.2.7 
php-src/ext/standard/dir.c:1.109.2.18.2.8
--- php-src/ext/standard/dir.c:1.109.2.18.2.7   Fri Jun 22 12:28:06 2007
+++ php-src/ext/standard/dir.c  Mon Jul 16 20:30:27 2007
@@ -16,7 +16,7 @@
+--+
  */
 
-/* $Id: dir.c,v 1.109.2.18.2.7 2007/06/22 12:28:06 pajoye Exp $ */
+/* $Id: dir.c,v 1.109.2.18.2.8 2007/07/16 20:30:27 tony2001 Exp $ */
 
 /* {{{ includes/startup/misc */
 
@@ -398,6 +398,7 @@
efree(dirname);
}
 
+   memset(globbuf, 0, sizeof(glob_t));
globbuf.gl_offs = 0;
if (0 != (ret = glob(pattern, flags  GLOB_FLAGMASK, NULL, globbuf))) {
 #ifdef GLOB_NOMATCH

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



[PHP-CVS] cvs: php-src /ext/sysvshm/tests 001.phpt

2007-07-16 Thread Antony Dovgal
tony2001Mon Jul 16 13:31:34 2007 UTC

  Modified files:  
/php-src/ext/sysvshm/tests  001.phpt 
  Log:
  fix test
  
  
http://cvs.php.net/viewvc.cgi/php-src/ext/sysvshm/tests/001.phpt?r1=1.1r2=1.2diff_format=u
Index: php-src/ext/sysvshm/tests/001.phpt
diff -u php-src/ext/sysvshm/tests/001.phpt:1.1 
php-src/ext/sysvshm/tests/001.phpt:1.2
--- php-src/ext/sysvshm/tests/001.phpt:1.1  Thu Jun 29 08:59:51 2006
+++ php-src/ext/sysvshm/tests/001.phpt  Mon Jul 16 13:31:34 2007
@@ -18,13 +18,13 @@
 echo Done\n;
 ?
 --EXPECTF--
-Warning: Wrong parameter count for ftok() in %s on line %d
+Warning: ftok() expects exactly 2 parameters, 0 given in %s on line %d
 NULL
 
-Warning: Wrong parameter count for ftok() in %s on line %d
+Warning: ftok() expects exactly 2 parameters, 1 given in %s on line %d
 NULL
 
-Warning: Wrong parameter count for ftok() in %s on line %d
+Warning: ftok() expects exactly 2 parameters, 3 given in %s on line %d
 NULL
 
 Warning: ftok(): Pathname is invalid 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/mbstring config.w32

2007-07-16 Thread Antony Dovgal
tony2001Mon Jul 16 19:07:22 2007 UTC

  Modified files:  
/php-src/ext/mbstring   config.w32 
  Log:
  there is no such file
  
  
http://cvs.php.net/viewvc.cgi/php-src/ext/mbstring/config.w32?r1=1.13r2=1.14diff_format=u
Index: php-src/ext/mbstring/config.w32
diff -u php-src/ext/mbstring/config.w32:1.13 
php-src/ext/mbstring/config.w32:1.14
--- php-src/ext/mbstring/config.w32:1.13Sun Feb  4 00:23:32 2007
+++ php-src/ext/mbstring/config.w32 Mon Jul 16 19:07:22 2007
@@ -1,4 +1,4 @@
-// $Id: config.w32,v 1.13 2007/02/04 00:23:32 fmk Exp $
+// $Id: config.w32,v 1.14 2007/07/16 19:07:22 tony2001 Exp $
 // vim:ft=javascript
 
 ARG_ENABLE(mbstring, multibyte string functions, no);
@@ -28,7 +28,6 @@
mbfilter_iso8859_2.c mbfilter_iso8859_3.c mbfilter_iso8859_4.c \
mbfilter_iso8859_5.c mbfilter_iso8859_6.c mbfilter_iso8859_7.c \
mbfilter_iso8859_8.c mbfilter_iso8859_9.c mbfilter_jis.c \
-   mbfilter_iso2022_jp_ms.c \
mbfilter_koi8r.c mbfilter_qprint.c mbfilter_sjis.c 
mbfilter_ucs2.c \
mbfilter_ucs4.c mbfilter_uhc.c mbfilter_utf16.c 
mbfilter_utf32.c \
mbfilter_utf7.c mbfilter_utf7imap.c mbfilter_utf8.c \

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