Hello, I got a segfault in sapi_cli_single_write. For an (yet) unknown reason, str becomes empty. The attached patch fixes it.
sidenote: found it by trying to resolve huge segfault in dom_xpath_query pierre
Index: sapi/cli/php_cli.c =================================================================== RCS file: /repository/php-src/sapi/cli/php_cli.c,v retrieving revision 1.107 diff -u -p -r1.107 php_cli.c --- sapi/cli/php_cli.c 14 Jan 2004 03:14:17 -0000 1.107 +++ sapi/cli/php_cli.c 19 Jan 2004 20:38:16 -0000 @@ -189,6 +189,10 @@ static inline size_t sapi_cli_single_wri #else size_t ret; + if (!str) { + return 0; + } + ret = fwrite(str, 1, MIN(str_length, 16384), stdout); return ret; #endif
-- PHP Internals - PHP Runtime Development Mailing List To unsubscribe, visit: http://www.php.net/unsub.php