You are viewing a plain text version of this content. The canonical link for it is here.
Posted to dev@httpd.apache.org by Zvi Har'El <rl...@math.technion.ac.il> on 2002/05/07 18:11:19 UTC
[PATCH] Re: proxy_cache handles "304 Not Modified" incorrectly
Dear Graham,
To make a long discusion short, I hereby insert my 3-liner patch (for
apache_1.3.24) for the problem. You'll be the judge.
--- proxy_cache.c.orig Wed Mar 13 23:05:32 2002
+++ proxy_cache.c Tue May 7 19:04:28 2002
@@ -1477,6 +1477,11 @@
ap_log_error(APLOG_MARK, APLOG_DEBUG|APLOG_NOERRNO, r->server, "Expiry date calculated %ld", (long)expc);
}
+/* Strip Content-Length from 304 reponse, in case buggy IIS-5.0 sends it! */
+ if (r->status == HTTP_NOT_MODIFIED) {
+ ap_table_unset(resp_hdrs, "Content-Length");
+ }
+
/* get the content-length header */
clen = ap_table_get(resp_hdrs, "Content-Length");
if (clen == NULL)
On Tue, 07 May 2002 18:38:49 +0300, Zvi Har'El wrote about "Re: proxy_cache handles "304 Not Modified" incorrectly":
> On Tue, 07 May 2002 09:44:05 +0200, Graham Leggett wrote about "Re: proxy_cache handles "304 Not Modified" incorrectly":
> > How many versions of IIS v5.0 (ie which service packs) are giving this
> > error? If it's fixed in a further service pack, then that should be the
> > encouraged solution.
>
> This is the most recent version of IIS which gives this error. No service pack
> on it.
--
Dr. Zvi Har'El mailto:rl@math.technion.ac.il Department of Mathematics
tel:+972-54-227607 Technion - Israel Institute of Technology
fax:+972-4-8324654 http://www.math.technion.ac.il/~rl/ Haifa 32000, ISRAEL
"If you can't say somethin' nice, don't say nothin' at all." -- Thumper (1942)
Tuesday, 26 Iyyar 5762, 7 May 2002, 7:06PM