Re: [PHP-DEV] lstat call on each directory level

2008-07-16 Thread Amir Hardon
On Wed, 2008-07-16 at 06:45 -0700, Rasmus Lerdorf wrote: Arvids Godjuks wrote: Hello. I think this should be optimized. I'm not an expert ofcourse, but as I understood there is only one case witch need a special treatment - require/include _one when a file with equal contents is

[PHP-DEV] lstat call on each directory level

2008-07-15 Thread Amir Hardon
Hi, I've noticed a weird behavior when doing file access from PHP: PHP seems to make an lstat call on each of the parent directories of the accessed file, for example see this script: ?php $fp=fopen(/var/www/metacafe/test,r); fclose($fp); ? When running with strace -e lstat I see this:

Re: [PHP-DEV] lstat call on each directory level

2008-07-15 Thread Amir Hardon
On Tue, 2008-07-15 at 11:40 -0700, Rasmus Lerdorf wrote: Amir Hardon wrote: I've noticed a weird behavior when doing file access from PHP: PHP seems to make an lstat call on each of the parent directories of the accessed file, for example see this script: ?php $fp=fopen(/var/www

Re: [PHP-DEV] lstat call on each directory level

2008-07-15 Thread Amir Hardon
On Tue, 2008-07-15 at 12:25 -0700, Rasmus Lerdorf wrote: Amir Hardon wrote: On Tue, 2008-07-15 at 11:40 -0700, Rasmus Lerdorf wrote: Amir Hardon wrote: I've noticed a weird behavior when doing file access from PHP: PHP seems to make an lstat call on each of the parent directories