ID: 27968 Updated by: [EMAIL PROTECTED] Reported By: apc at guidoni dot com -Status: Open +Status: Feedback Bug Type: Reproducible crash Operating System: SCO_SV localhost 3.2 5.0.5 i386 PHP Version: 4CVS-2004-04-12 (stable) New Comment:
See bug #24457 and try the patch provided by Ilia. Previous Comments: ------------------------------------------------------------------------ [2004-04-12 18:43:34] apc at guidoni dot com i am not sure what you mean by it works fine there. do you have an sco os 5.0.5 box and the rest of the blah? i had no part of the decision to go with sco and would probably go with micro$oft before any sco product. with that aside, i just try to help the client, who was sold the sco solution by someone else. will you please take a look at this? i am not sure it is system based, looking at main.c and cgi_main.c, it looks like php is not able to build the argvs correctly, starting with argv[0] the scriptname. perhaps because of a broken getcwd?? ------------------------------------------------------------------------ [2004-04-12 18:19:42] [EMAIL PROTECTED] This is just something broken in your system, it works fine here. Also, we are not really interested in debugging this for SCO Unix. ------------------------------------------------------------------------ [2004-04-12 18:11:56] apc at guidoni dot com Description: ------------ php-4.3.5 does not compile; php4-STABLE-200404061630 and php4-STABLE-200404122030 compile without problems. ./configure --with-curl stock php.ini PHP 4.3.6RC4-dev (cli) (built: Apr 12 2004 14:16:24) Copyright (c) 1997-2004 The PHP Group Zend Engine v1.3.0, Copyright (c) 1998-2004 Zend Technologies both snaps fail with shebangs and when calling the cli version with the filename as the argument, eg `php foobar.php'. [EMAIL PROTECTED] 1% php abc.php php: Segmentation violation -- Core dumped [EMAIL PROTECTED] 2% [EMAIL PROTECTED] 3% php ./abc.php php: Segmentation violation -- Core dumped [EMAIL PROTECTED] 4% [EMAIL PROTECTED] 5% php ~/abc.php hello world [EMAIL PROTECTED] 6% [EMAIL PROTECTED] 7% php /usr/user/abc.php hello world [EMAIL PROTECTED] 8% --add the shebang #!/usr/local/bin/php to abc.php-- [EMAIL PROTECTED] 9% chmod u+x abc.php [EMAIL PROTECTED] 10% ./abc.php php: Segmentation violation -- Core dumped [EMAIL PROTECTED] 11% [EMAIL PROTECTED] 12% set path =(~/bin $path) [EMAIL PROTECTED] 13% cp abc.php ~/bin [EMAIL PROTECTED] 14% abc.php hello world [EMAIL PROTECTED] 15% [EMAIL PROTECTED] 16% /usr/user/abc.php hello world [EMAIL PROTECTED] 17% Reproduce code: --------------- <?php echo "hello world\n"; ?> or #!/usr/local/bin/php <?php echo "hello world\n"; ?> Expected result: ---------------- hello world Actual result: -------------- [EMAIL PROTECTED] 6% php abc.php php: Segmentation violation -- Core dumped [EMAIL PROTECTED] 7% gdb /usr/local/bin/php core GNU gdb 5.3 Copyright 2002 Free Software Foundation, Inc. GDB is free software, covered by the GNU General Public License, and you are welcome to change it and/or distribute copies of it under certain conditions. Type "show copying" to see the conditions. There is absolutely no warranty for GDB. Type "show warranty" for details. This GDB was configured as "i586-pc-sco3.2v5.0"... Core was generated by `php'. Program terminated with signal 11, Segmentation fault. #0 0x80030232 in ?? () (gdb) (gdb) bt #0 0x80030232 in ?? () #1 0x800a4cd0 in ?? () #2 0x800a4fb0 in ?? () #3 0x08104568 in php_execute_script (primary_file=0x8047d58) at /usr/user/php/php4-STABLE- 200404061630/main/main.c:1694 #4 0x08141ecd in main (argc=2, argv=0x8047d8c) at / usr/user/php/php4-STABLE-200404061630/sapi/cgi/ cgi_main.c:1339 #5 0x08060dae in _start () (gdb) ------------------------------------------------------------------------ -- Edit this bug report at http://bugs.php.net/?id=27968&edit=1
