diff options
author | Nick Mathewson <nickm@torproject.org> | 2012-03-08 21:09:34 -0500 |
---|---|---|
committer | Nick Mathewson <nickm@torproject.org> | 2012-05-16 12:14:48 -0400 |
commit | 1abe533b3304619bd8c59f170097ab469af99dc9 (patch) | |
tree | c4be4391d89f0e7958378a9203cdc3cf9ccad1b2 /src/test | |
parent | d0d9c3d71e1fb88557d684c59cf8a920712b16f1 (diff) | |
download | tor-1abe533b3304619bd8c59f170097ab469af99dc9.tar.gz tor-1abe533b3304619bd8c59f170097ab469af99dc9.zip |
Reject an additional type of bad date in parse_http_time
Diffstat (limited to 'src/test')
-rw-r--r-- | src/test/test_util.c | 1 |
1 files changed, 1 insertions, 0 deletions
diff --git a/src/test/test_util.c b/src/test/test_util.c index 5845d779be..e239326a2d 100644 --- a/src/test/test_util.c +++ b/src/test/test_util.c @@ -101,6 +101,7 @@ test_util_parse_http_time(void *arg) test_eq(-1, parse_http_time("Sunday, 32-Aug-94 00:48:22 GMT", &a_time)); test_eq(-1, parse_http_time("Sunday, 3-Ago-04 00:48:22", &a_time)); test_eq(-1, parse_http_time("Sunday, August the third", &a_time)); + test_eq(-1, parse_http_time("Wednesday,,04 Aug 1994 00:48:22 GMT", &a_time)); test_eq(0, parse_http_time("Wednesday, 04 Aug 1994 00:48:22 GMT", &a_time)); test_eq((time_t)775961302UL, tor_timegm(&a_time)); |