diff options
Diffstat (limited to 'src/or/directory.c')
-rw-r--r-- | src/or/directory.c | 3 |
1 files changed, 2 insertions, 1 deletions
diff --git a/src/or/directory.c b/src/or/directory.c index 29cf10cea0..975f8910cd 100644 --- a/src/or/directory.c +++ b/src/or/directory.c @@ -2493,7 +2493,8 @@ directory_handle_command_get(dir_connection_t *conn, const char *headers, if ((header = http_get_header(headers, "If-Modified-Since: "))) { struct tm tm; if (parse_http_time(header, &tm) == 0) { - if_modified_since = tor_timegm(&tm); + if (tor_timegm(&tm, &if_modified_since)<0) + if_modified_since = 0; } /* The correct behavior on a malformed If-Modified-Since header is to * act as if no If-Modified-Since header had been given. */ |