Re: Should php3_fopen_for_parser change the current working directory?
| From: | Rasmus Lerdorf | Date: | Thu, 01 Jan 1970 00:00:00 +0000 |
| Subject: | Re: Should php3_fopen_for_parser change the current working directory? | ||
| References: | 1 | Groups: | php.dev |
| Request: | Send a blank email to php-dev+get-13014@lists.php.net to get a copy of this message | ||
On Tue, 23 Nov 1999 rubys@us.ibm.com wrote:
> I'd like to remove the following code, and was wondering if anybody had an
> objection:
>
> temp = estrdup(fn);
> php_dirname(temp, strlen(temp));
> if (*temp) {
> chdir(temp);
> }
> efree(temp);
>
> It seems to me that this is looking for trouble (particularly when running
> under a multi-threaded web server!)
>
> In particular, it blows me out of the water for making further progress on
> running PHP as a servlet.
It would break a whole lot of scripts out there that expect to be in the
same dir as the script being executed.
-Rasmus