jani            Mon Apr 28 12:30:24 2008 UTC

  Modified files:              (Branch: PHP_5_3)
    /php-src/ext/standard/tests/file    bug22414.phpt 
  Log:
  - Fix test even if safe_mode is forced to be "On" in the binary
  
http://cvs.php.net/viewvc.cgi/php-src/ext/standard/tests/file/bug22414.phpt?r1=1.10.6.2&r2=1.10.6.2.2.1&diff_format=u
Index: php-src/ext/standard/tests/file/bug22414.phpt
diff -u php-src/ext/standard/tests/file/bug22414.phpt:1.10.6.2 
php-src/ext/standard/tests/file/bug22414.phpt:1.10.6.2.2.1
--- php-src/ext/standard/tests/file/bug22414.phpt:1.10.6.2      Wed Apr 18 
14:51:29 2007
+++ php-src/ext/standard/tests/file/bug22414.phpt       Mon Apr 28 12:30:24 2008
@@ -8,20 +8,21 @@
 
        $php = getenv('TEST_PHP_EXECUTABLE');
        $tmpfile = tempnam('/tmp', 'phpt');
+       $args = ' -n -dsafe_mode=off ';
        
        /* Regular Data Test */
-       passthru($php . ' -n -r " echo \"HELLO\"; "');
+       passthru($php . $args . ' -r " echo \"HELLO\"; "');
 
        echo "\n";
 
        /* Binary Data Test */
        
        if (substr(PHP_OS, 0, 3) != 'WIN') {
-               $cmd = $php . ' -n -r 
\"readfile(@getenv(\'TEST_PHP_EXECUTABLE\')); \"';
-               $cmd = $php . ' -n -r \' passthru("'.$cmd.'"); \' > '.$tmpfile ;
+               $cmd = $php . $args . ' -r 
\"readfile(@getenv(\'TEST_PHP_EXECUTABLE\')); \"';
+               $cmd = $php . $args . ' -r \' passthru("'.$cmd.'"); \' > 
'.$tmpfile ;
        } else {
-               $cmd = $php . ' -n -r 
\"readfile(@getenv(\\\\\\"TEST_PHP_EXECUTABLE\\\\\\")); \"';
-               $cmd = $php . ' -n -r " passthru(\''.$cmd.'\');" > '.$tmpfile ;
+               $cmd = $php . $args . ' -r 
\"readfile(@getenv(\\\\\\"TEST_PHP_EXECUTABLE\\\\\\")); \"';
+               $cmd = $php . $args . ' -r " passthru(\''.$cmd.'\');" > 
'.$tmpfile ;
        }
        exec($cmd);
 



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

Reply via email to