ID: 17193 Updated by: [EMAIL PROTECTED] Reported By: [EMAIL PROTECTED] -Status: Open +Status: Feedback Bug Type: Scripting Engine problem Operating System: RH Linux 7.2/Apach 1.3.22 PHP Version: 4.1.2 New Comment:
Thank you for this bug report. To properly diagnose the problem, we need a backtrace to see what is happening behind the scenes. To find out how to generate a backtrace, please read http://bugs.php.net/bugs-generating-backtrace.php Once you have generated a backtrace, please submit it to this bug report and change the status back to "Open". Thank you for helping us make PHP better. You can find ho wto make a backtrace on the location mentioned above. Derick Previous Comments: ------------------------------------------------------------------------ [2002-05-13 19:25:57] [EMAIL PROTECTED] If you call register_shutdown_function, and then in the registered function make a call to getenv, Apache segfaults. Here's a sample script: <?PHP function shutdowner() { $out = fopen("/tmp/env.out", "at"); fwrite($out, "getenv returned " . getenv("HOME") . "\n"); fclose($out); } echo "Getenv returned " . getenv("HOME") . "\n"; register_shutdown_function("shutdowner"); ?> Please note. This only happens when running as an apache module. CLI works fine, and I'd assume that CGI does too. I'll post a back trace if some kind soul will explain how to do it under RH linux using the messed up !apachectl method that they use to start apache. ------------------------------------------------------------------------ -- Edit this bug report at http://bugs.php.net/?id=17193&edit=1