httpd-dev mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From (Rodent of Unusual Size)
Subject Re: [PATCH] (PR 894,895) ETags, Last-Modified, and scripts
Date Fri, 22 Aug 1997 00:47:41 GMT
>From the fingers of "Roy T. Fielding" flowed the following:
>Generality is good, but there is always a balance between the need for
>abstraction and the need for performance.  Given that we already know
>that mtime is needed for at least one condition, it should be passed-in
>either as its own parameter or as part of the request_rec.

    Oooh, I like the latter idea.  I like it a *lot*.  I think that
    could save even more cycles and normalise a bunch of stuff.  Need to
    define semantics for setting it, though; how about

    if ((r->mtime == 0) && (passed-in mtime != 0))
	r->mtime = passed-in mtime
    if ((r->mtime == 0) && (r->finfo.st_mtime !=0))
	r->mtime = r->finfo.st_mtime

    Put these into a set_request_mtime() routine and let things like
    set_last_modified() (and other things that wave the mtime around)
    call it before trying to use r->mtime.

    #ken    :-)}

View raw message