httpd-dev mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From "Roy T. Fielding" <field...@liege.ICS.UCI.EDU>
Subject Re: another http/1.0 bug in set_last_modified
Date Sat, 28 Sep 1996 05:03:33 GMT
> I think this patch to 1.2-dev fixes the problem.  Main issue - server_time no
> longer available, now it's r->request_time (I think - can anyone confirm?)

Yes on r->request_time, but the patch has a different problem:

> taz [265] cvs diff -C3 http_protocol.c
> Index: http_protocol.c
> ===================================================================
> RCS file: /export/home/cvs/apache/src/http_protocol.c,v
> retrieving revision 1.47
> diff -C3 -r1.47 http_protocol.c
> *** http_protocol.c     1996/09/24 12:44:57     1.47
> --- http_protocol.c     1996/09/28 01:28:17
> ***************
> *** 331,337 ****
>       /* Invalid, future time... just ignore it */
>       if (mtime > r->request_time) return OK;
>   
> !     ts = gm_timestr_822(r->pool, mtime);
>       table_set (r->headers_out, "Last-Modified", ts);
>   
>       /* Make an ETag header out of various peices of information. We use
> --- 331,337 ----
>       /* Invalid, future time... just ignore it */
>       if (mtime > r->request_time) return OK;
>   
> !     ts = gm_timestr_822(r->pool, (mtime > r->request_time) ? r->request_time
: mtime);
>       table_set (r->headers_out, "Last-Modified", ts);
>   
>       /* Make an ETag header out of various peices of information. We use

The if condition just above that change is (mtime > r->request_time),
which means the one inside gm_timestr_822 is a NOP.  I think it would
be best to delete the

>       /* Invalid, future time... just ignore it */
>       if (mtime > r->request_time) return OK;

since it isn't needed any more.

......Roy

Mime
View raw message