Index: trunk/phase3/includes/GlobalFunctions.php |
— | — | @@ -2326,9 +2326,12 @@ |
2327 | 2327 | $cmd = escapeshellarg( $script ) . " $time $mem $filesize " . escapeshellarg( $cmd ); |
2328 | 2328 | } |
2329 | 2329 | } |
2330 | | - } elseif ( php_uname( 's' ) == 'Windows NT' && substr( php_uname( 'v' ), 6, 4 ) <= 6001 ) { |
| 2330 | + } elseif ( php_uname( 's' ) == 'Windows NT' && |
| 2331 | + version_compare( PHP_VERSION, '5.3.0', '<' ) ) |
| 2332 | + { |
2331 | 2333 | # This is a hack to work around PHP's flawed invocation of cmd.exe |
2332 | 2334 | # http://news.php.net/php.internals/21796 |
| 2335 | + # Which is fixed in 5.3.0 :) |
2333 | 2336 | $cmd = '"' . $cmd . '"'; |
2334 | 2337 | } |
2335 | 2338 | wfDebug( "wfShellExec: $cmd\n" ); |