httpd-dev mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From Dmitry Khrustalev <d...@bog.msu.su>
Subject Re: cvs commit: apache-1.3 STATUS
Date Mon, 04 May 1998 15:02:35 GMT

On Mon, 4 May 1998, Dean Gaudet wrote:
> On Mon, 4 May 1998, Michael Douglass wrote:
> > >   +    * The DoS issue about symlinks to /dev/zero is still present.
> > >   +      A device checker patch had been sent to the list a while ago.
> > >   +      Msg-Id: ?
> > >   +       Jim: Couldn't we just use stat() and check the file-type?
> > >   +            stats are expensive though...
> > 
> > I was just sitting here thinking of a way to handle this.  Instead of
> > trying to detect this information every time you transfer a file;
> 
> We already need to stat() for every hit -- last-modified, and
> content-length for example are required.  There's already a test for
> devices and such.  Marc mentioned that the problem is config files I
> think. 

stat is expensive because it has to run namei, fstat is not so expensive.
opening file in get_path_info, and saving fd in request_rec and using this
saved fd later saves ~1/6 of system time here.

	-Dima


Mime
View raw message