diff options
author | Nick Mathewson <nickm@torproject.org> | 2012-09-11 13:20:15 -0400 |
---|---|---|
committer | Nick Mathewson <nickm@torproject.org> | 2012-09-11 13:20:15 -0400 |
commit | 5833861f62d2667eeda1ed0f6595763aa00250b0 (patch) | |
tree | 654dcbc4cd6faf1a30d9e0ce5fbc9025d89e8f8c /src/test/test_util.c | |
parent | 8731a4e148e23d8edbb7f32bdfeee30c326f33cc (diff) | |
parent | 84f47ffc462dface8db1def322414daa43400d1c (diff) | |
download | tor-5833861f62d2667eeda1ed0f6595763aa00250b0.tar.gz tor-5833861f62d2667eeda1ed0f6595763aa00250b0.zip |
Merge remote-tracking branch 'origin/maint-0.2.2' into maint-0.2.3
Conflicts:
src/test/test_util.c
Diffstat (limited to 'src/test/test_util.c')
-rw-r--r-- | src/test/test_util.c | 13 |
1 files changed, 13 insertions, 0 deletions
diff --git a/src/test/test_util.c b/src/test/test_util.c index 9eca90492d..4f9eb73e03 100644 --- a/src/test/test_util.c +++ b/src/test/test_util.c @@ -18,6 +18,19 @@ #include <tchar.h> #endif +/* XXXX this is a minimal wrapper to make the unit tests compile with the + * changed tor_timegm interface. */ +static time_t +tor_timegm_wrapper(const struct tm *tm) +{ + time_t t; + if (tor_timegm(tm, &t) < 0) + return -1; + return t; +} + +#define tor_timegm tor_timegm_wrapper + static void test_util_time(void) { |