commit 7072dd5dbe28b9eedfeb9ca743f6db8b7ed08a57 Author: George Kadianakis desnacked@riseup.net Date: Thu Sep 13 18:00:06 2012 +0300
Add a unit test for the old crash input of tor_timegm(). --- 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 7ef4d1f..ad49421 100644 --- a/src/test/test_util.c +++ b/src/test/test_util.c @@ -152,6 +152,7 @@ test_util_time(void) test_eq(-1, parse_iso_time("2011-03-30 23:59:62 GMT", &t_res)); test_eq(-1, parse_iso_time("1969-03-30 23:59:59 GMT", &t_res)); test_eq(-1, parse_iso_time("2011-00-30 23:59:59 GMT", &t_res)); + test_eq(-1, parse_iso_time("2147483647-08-29 14:00:00", &t_res)); test_eq(-1, parse_iso_time("2011-03-30 23:59", &t_res));
/* Test tor_gettimeofday */