Ticket #1322 (closed defect: fixed)
etags checked in http-header-glue.c even when unconfigured
| Reported by: | ethan@… | Owned by: | jan |
|---|---|---|---|
| Priority: | normal | Milestone: | 1.4.17 |
| Component: | core | Version: | 1.4.16 |
| Severity: | normal | Keywords: | etag |
| Cc: | Blocked By: | ||
| Need User Feedback: | no | Blocking: |
Description
I have etags disabled via the new 1.4.16 feature, but when a if-none-match header is received it still tries to issue a etag_is_equal (etag.c) in http_response_handle_cachable (http-header-glue.c). This patch checks if con->physical.etag is defined before calling etag_is_equal. I believe this is somewhat rare, because I think it needs to come from a prior request where ETag was set, and now it's not configured.
--- http-header-glue.c.orig 2007-08-23 11:09:48.000000000 -0700
+++ http-header-glue.c 2007-08-23 11:08:44.000000000 -0700
@@ -241,7 +241,7 @@
*/
/* last-modified handling */
- if (con->request.http_if_none_match) {
+ if (con->request.http_if_none_match && con->physical.etag) {
if (etag_is_equal(con->physical.etag, con->request.http_if_none_match)) {
if (con->request.http_method == HTTP_METHOD_GET ||
con->request.http_method == HTTP_METHOD_HEAD) {
Attachments
Change History
Note: See
TracTickets for help on using
tickets.

