diff options
author | Nick Mathewson <nickm@torproject.org> | 2017-01-31 13:02:49 -0500 |
---|---|---|
committer | Nick Mathewson <nickm@torproject.org> | 2017-01-31 13:02:49 -0500 |
commit | d183ec231be0e3f560f844bf2d118e2c71bda25f (patch) | |
tree | a1c82cf239eeba387887b0e59297b19b40fe0c85 /src | |
parent | 0d4d9b6d889de6dc85ca8870ada123aaf41b0053 (diff) | |
download | tor-d183ec231be0e3f560f844bf2d118e2c71bda25f.tar.gz tor-d183ec231be0e3f560f844bf2d118e2c71bda25f.zip |
Call monotime_init() earlier.
We need to call it before nt_service_parse_options(), since
nt_service_parse_options() can call back into nt_service_main(),
which calls do_main_loop().
Fixes bug 21356; bugfix on 0.2.9.1-alpha.
Diffstat (limited to 'src')
-rw-r--r-- | src/or/main.c | 3 |
1 files changed, 1 insertions, 2 deletions
diff --git a/src/or/main.c b/src/or/main.c index 66a8571901..89cfb2e2ff 100644 --- a/src/or/main.c +++ b/src/or/main.c @@ -3443,6 +3443,7 @@ tor_main(int argc, char *argv[]) update_approx_time(time(NULL)); tor_threads_init(); init_logging(0); + monotime_init(); #ifdef USE_DMALLOC { /* Instruct OpenSSL to use our internal wrappers for malloc, @@ -3476,8 +3477,6 @@ tor_main(int argc, char *argv[]) #endif } - monotime_init(); - switch (get_options()->command) { case CMD_RUN_TOR: #ifdef NT_SERVICE |