From: jostb2345 at yahoo dot com Operating system: Windows (all versions) PHP version: 5.2.1 PHP Bug Type: Reproducible crash Bug description: Test fcgi_is_fastcgi() is wrong on windows
Description: ------------ On windows, php 5.2.0 and above the following code (written in pseudo-code) doesn't work anymore: socket = socket(AF_INET, ...); bind(socket, ...); listen(socket, ...); outputHandle=GetStdHandle(...); inputHandle=socket; CreateProcess(...,"php-cgi.exe", ..., IOHandles); The problem is that "is_fastcgi" is only set if the OutputHandle and ErrorHandle are invalid. If both are invalid, InputHandle is assumed to be a named pipe. The Unix version still uses the old (correct) code. To correct this problem either the old FCGI_isfcgi() should be used or the test must be dublicated. See procedures: int fcgi_init(void); int fcgi_is_fastcgi(void); Regards, Jost Boekemeier Reproduce code: --------------- See above. If necessary I can provide a test program. -- Edit bug report at http://bugs.php.net/?id=40758&edit=1 -- Try a CVS snapshot (PHP 4.4): http://bugs.php.net/fix.php?id=40758&r=trysnapshot44 Try a CVS snapshot (PHP 5.2): http://bugs.php.net/fix.php?id=40758&r=trysnapshot52 Try a CVS snapshot (PHP 6.0): http://bugs.php.net/fix.php?id=40758&r=trysnapshot60 Fixed in CVS: http://bugs.php.net/fix.php?id=40758&r=fixedcvs Fixed in release: http://bugs.php.net/fix.php?id=40758&r=alreadyfixed Need backtrace: http://bugs.php.net/fix.php?id=40758&r=needtrace Need Reproduce Script: http://bugs.php.net/fix.php?id=40758&r=needscript Try newer version: http://bugs.php.net/fix.php?id=40758&r=oldversion Not developer issue: http://bugs.php.net/fix.php?id=40758&r=support Expected behavior: http://bugs.php.net/fix.php?id=40758&r=notwrong Not enough info: http://bugs.php.net/fix.php?id=40758&r=notenoughinfo Submitted twice: http://bugs.php.net/fix.php?id=40758&r=submittedtwice register_globals: http://bugs.php.net/fix.php?id=40758&r=globals PHP 3 support discontinued: http://bugs.php.net/fix.php?id=40758&r=php3 Daylight Savings: http://bugs.php.net/fix.php?id=40758&r=dst IIS Stability: http://bugs.php.net/fix.php?id=40758&r=isapi Install GNU Sed: http://bugs.php.net/fix.php?id=40758&r=gnused Floating point limitations: http://bugs.php.net/fix.php?id=40758&r=float No Zend Extensions: http://bugs.php.net/fix.php?id=40758&r=nozend MySQL Configuration Error: http://bugs.php.net/fix.php?id=40758&r=mysqlcfg
