ID: 14251 Updated by: [EMAIL PROTECTED] Reported By: [EMAIL PROTECTED] Status: Critical Bug Type: Scripting Engine problem Operating System: Linux Mandrake 8.0 PHP Version: 4.1.0 Assigned To: zeev New Comment:
IIRC (!) this was some problem with the cwd funcs in TSRM. Can't remember now what exactly it was.. (it works in windows but not in *nix) Previous Comments: ------------------------------------------------------------------------ [2002-09-19 11:08:13] [EMAIL PROTECTED] This isn't related to #11831. It has to do with the fact that by the time we're shutting down, we're no longer in the request context, but rather, in Apache's shutdown context. Apache is probably changing directory to / at this stage. I'm not sure why this is tagged as critical, I'm not sure whether this should be 'fixed'. My recommendation is to move it to 'Analyzed' status. ------------------------------------------------------------------------ [2002-09-03 18:35:56] [EMAIL PROTECTED] Another one related to #11831 ------------------------------------------------------------------------ [2002-08-05 16:48:02] [EMAIL PROTECTED] I have reproduced this too on PHP 4.2.2 and Linux RH 6.2. However it does not seem to occur in Windows. Workaround by putting getcwd() into a global variable before shutdown then using chdir() in the shutdown_function. ------------------------------------------------------------------------ [2001-11-27 12:48:47] [EMAIL PROTECTED] Reproduced. Seems like cwd changes to / always. ------------------------------------------------------------------------ [2001-11-27 12:04:10] [EMAIL PROTECTED] Current directory in main program body and into shutdown function is not same. Sometimes its changes to '/' or something else. Try to execute this script and reload page some times: <? set_time_limit(0); ignore_user_abort(0); function Test() { echo "Shutdown function: ", `pwd`; }; echo "Body: ", `pwd`; register_shutdown_function ("Test"); ?><BR> ------------------------------------------------------------------------ -- Edit this bug report at http://bugs.php.net/?id=14251&edit=1