Re: Re: Current working directory and multi-threaded environments

From: Date: Wed, 15 Mar 2000 19:27:46 +0000
Subject: Re: Re: Current working directory and multi-threaded environments
References: 1  Groups: php.dev 
Request: Send a blank email to php-dev+get-16853@lists.php.net to get a copy of this message
On Wed, Mar 15, 2000 at 02:21:51PM -0500, rubys@us.ibm.com wrote: > > > >> I'm not sure if I need to do the real getcwd() per-request or if doing > it > >> on PHP startup once is good enough. > > > >Why should a threaded web server change its per-process > >work directory? > > I'm confused. getwd doesn't change the working directory, right? We are talking about reacting (getcwd) to an action by the server (chdir). Fortunately, this action does not take place. I think we should always start with cwd = dirname(executing_script). (Perhaps the code fragment you posted does that.) That would mean that we do not need to execute getcwd at all. Thoughts? - Sascha

« previous php.dev (#16853) next »