From d4d77b277e72c74a47bd724531426d7f561607e4 Mon Sep 17 00:00:00 2001 From: Neel Chauhan Date: Wed, 3 Apr 2019 11:36:52 -0400 Subject: [PATCH 01/10] Stop setting bridges running in networkstatus_getinfo_by_purpose() --- changes/bug24490 | 5 +++++ scripts/maint/practracker/exceptions.txt | 6 +++--- src/core/mainloop/mainloop.c | 25 ++++++++++++++++++++++++ src/feature/nodelist/networkstatus.c | 4 ---- 4 files changed, 33 insertions(+), 7 deletions(-) create mode 100644 changes/bug24490 diff --git a/changes/bug24490 b/changes/bug24490 new file mode 100644 index 0000000000..9ae09dbd17 --- /dev/null +++ b/changes/bug24490 @@ -0,0 +1,5 @@ + o Minor bugfixes (bridge authority): + - We set bridges as running in a callback which runs every 5 minutes. + Previously, we set bridges as running in a GETINFO controller as + these shouldn't modify vital data structures. Fixes bug 24490; + bugfix on 0.2.0.13-alpha. Patch by Neel Chauhan diff --git a/scripts/maint/practracker/exceptions.txt b/scripts/maint/practracker/exceptions.txt index ad5d3e9725..a9fcf9095a 100644 --- a/scripts/maint/practracker/exceptions.txt +++ b/scripts/maint/practracker/exceptions.txt @@ -67,11 +67,11 @@ problem function-size /src/core/mainloop/connection.c:connection_handle_read_imp problem function-size /src/core/mainloop/connection.c:connection_buf_read_from_socket() 177 problem function-size /src/core/mainloop/connection.c:connection_handle_write_impl() 241 problem function-size /src/core/mainloop/connection.c:assert_connection_ok() 143 -problem file-size /src/core/mainloop/mainloop.c 3051 -problem include-count /src/core/mainloop/mainloop.c 66 +problem file-size /src/core/mainloop/mainloop.c 3076 +problem include-count /src/core/mainloop/mainloop.c 68 problem function-size /src/core/mainloop/mainloop.c:conn_close_if_marked() 108 problem function-size /src/core/mainloop/mainloop.c:run_connection_housekeeping() 123 -problem function-size /src/core/mainloop/mainloop.c:CALLBACK() 116 +problem function-size /src/core/mainloop/mainloop.c:CALLBACK() 118 problem file-size /src/core/or/channel.c 3476 problem function-size /src/core/or/channeltls.c:channel_tls_handle_var_cell() 160 problem function-size /src/core/or/channeltls.c:channel_tls_process_versions_cell() 170 diff --git a/src/core/mainloop/mainloop.c b/src/core/mainloop/mainloop.c index c9f2b0d896..800304a736 100644 --- a/src/core/mainloop/mainloop.c +++ b/src/core/mainloop/mainloop.c @@ -76,6 +76,7 @@ #include "feature/control/control_events.h" #include "feature/dirauth/authmode.h" #include "feature/dirauth/reachability.h" +#include "feature/dirauth/voteflags.h" #include "feature/dircache/consdiffmgr.h" #include "feature/dircache/dirserv.h" #include "feature/dircommon/directory.h" @@ -87,6 +88,7 @@ #include "feature/nodelist/networkstatus.h" #include "feature/nodelist/nodelist.h" #include "feature/nodelist/routerlist.h" +#include "feature/nodelist/routerlist_st.h" #include "feature/relay/dns.h" #include "feature/relay/routerkeys.h" #include "feature/relay/routermode.h" @@ -1375,6 +1377,7 @@ CALLBACK(rotate_onion_key); CALLBACK(rotate_x509_certificate); CALLBACK(save_stability); CALLBACK(save_state); +CALLBACK(set_bridge_running); CALLBACK(write_bridge_ns); CALLBACK(write_stats_file); CALLBACK(control_per_second_events); @@ -1453,6 +1456,7 @@ STATIC periodic_event_item_t periodic_events[] = { /* Bridge Authority only. */ CALLBACK(write_bridge_ns, BRIDGEAUTH, 0), + CALLBACK(set_bridge_running, BRIDGEAUTH, 0), /* Directory server only. */ CALLBACK(clean_consdiffmgr, DIRSERVER, 0), @@ -2583,6 +2587,27 @@ write_bridge_ns_callback(time_t now, const or_options_t *options) return PERIODIC_EVENT_NO_UPDATE; } +/** + * Periodic callback: if we're the bridge authority, set the running flag on + * bridges if they're reachable + */ +static int +set_bridge_running_callback(time_t now, const or_options_t *options) +{ + if (options->BridgeAuthoritativeDir) { + routerlist_t *rl = router_get_routerlist(); + + SMARTLIST_FOREACH_BEGIN(rl->routers, routerinfo_t *, ri) { + if (ri->purpose == ROUTER_PURPOSE_BRIDGE) + dirserv_set_router_is_running(ri, now); + } SMARTLIST_FOREACH_END(ri); + +#define SET_BRIDGES_RUNNING_INTERVAL (3*60) + return SET_BRIDGES_RUNNING_INTERVAL; + } + return PERIODIC_EVENT_NO_UPDATE; +} + static int heartbeat_callback_first_time = 1; /** diff --git a/src/feature/nodelist/networkstatus.c b/src/feature/nodelist/networkstatus.c index ea9f12367f..bc12fa4075 100644 --- a/src/feature/nodelist/networkstatus.c +++ b/src/feature/nodelist/networkstatus.c @@ -2378,7 +2378,6 @@ networkstatus_getinfo_by_purpose(const char *purpose_string, time_t now) smartlist_t *statuses; const uint8_t purpose = router_purpose_from_string(purpose_string); routerstatus_t rs; - const int bridge_auth = authdir_mode_bridge(get_options()); if (purpose == ROUTER_PURPOSE_UNKNOWN) { log_info(LD_DIR, "Unrecognized purpose '%s' when listing router statuses.", @@ -2395,9 +2394,6 @@ networkstatus_getinfo_by_purpose(const char *purpose_string, time_t now) continue; if (ri->purpose != purpose) continue; - /* TODO: modifying the running flag in a getinfo is a bad idea */ - if (bridge_auth && ri->purpose == ROUTER_PURPOSE_BRIDGE) - dirserv_set_router_is_running(ri, now); /* then generate and write out status lines for each of them */ set_routerstatus_from_routerinfo(&rs, node, ri, now, 0); smartlist_add(statuses, networkstatus_getinfo_helper_single(&rs)); From aa9940ed21e890ddbb0a3541bf15e7cca4c3b489 Mon Sep 17 00:00:00 2001 From: Neel Chauhan Date: Thu, 11 Apr 2019 20:24:08 -0400 Subject: [PATCH 02/10] Make SET_BRIDGES_RUNNING_INTERVAL 5 minutes --- src/core/mainloop/mainloop.c | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/src/core/mainloop/mainloop.c b/src/core/mainloop/mainloop.c index 800304a736..7609c630c8 100644 --- a/src/core/mainloop/mainloop.c +++ b/src/core/mainloop/mainloop.c @@ -2602,7 +2602,7 @@ set_bridge_running_callback(time_t now, const or_options_t *options) dirserv_set_router_is_running(ri, now); } SMARTLIST_FOREACH_END(ri); -#define SET_BRIDGES_RUNNING_INTERVAL (3*60) +#define SET_BRIDGES_RUNNING_INTERVAL (5*60) return SET_BRIDGES_RUNNING_INTERVAL; } return PERIODIC_EVENT_NO_UPDATE; From 30279a7c575d2b27055e511a2f8cf84336387bb8 Mon Sep 17 00:00:00 2001 From: Neel Chauhan Date: Thu, 11 Apr 2019 20:28:11 -0400 Subject: [PATCH 03/10] Use authdir_mode_bridge() in set_bridge_running_callback() --- src/core/mainloop/mainloop.c | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/src/core/mainloop/mainloop.c b/src/core/mainloop/mainloop.c index 7609c630c8..fd711fd3bc 100644 --- a/src/core/mainloop/mainloop.c +++ b/src/core/mainloop/mainloop.c @@ -2594,7 +2594,7 @@ write_bridge_ns_callback(time_t now, const or_options_t *options) static int set_bridge_running_callback(time_t now, const or_options_t *options) { - if (options->BridgeAuthoritativeDir) { + if (authdir_mode_bridge(options)) { routerlist_t *rl = router_get_routerlist(); SMARTLIST_FOREACH_BEGIN(rl->routers, routerinfo_t *, ri) { From e16f5184dad6d0052df37496327e2652d9c79d00 Mon Sep 17 00:00:00 2001 From: Neel Chauhan Date: Thu, 11 Apr 2019 20:32:38 -0400 Subject: [PATCH 04/10] Fix grammar in bug24490 changes file --- changes/bug24490 | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/changes/bug24490 b/changes/bug24490 index 9ae09dbd17..1167e9f8d3 100644 --- a/changes/bug24490 +++ b/changes/bug24490 @@ -1,5 +1,5 @@ o Minor bugfixes (bridge authority): - We set bridges as running in a callback which runs every 5 minutes. - Previously, we set bridges as running in a GETINFO controller as + Previously, we set bridges as running in a GETINFO controller, but these shouldn't modify vital data structures. Fixes bug 24490; bugfix on 0.2.0.13-alpha. Patch by Neel Chauhan From 4172dcaa62b02593910736110d9d2c94052dbdcb Mon Sep 17 00:00:00 2001 From: Neel Chauhan Date: Thu, 11 Apr 2019 20:44:30 -0400 Subject: [PATCH 05/10] Move code for setting bridges as running to voteflags.c --- scripts/maint/practracker/exceptions.txt | 4 ++-- src/core/mainloop/mainloop.c | 7 +------ src/feature/dirauth/voteflags.c | 18 ++++++++++++++++++ src/feature/dirauth/voteflags.h | 2 ++ 4 files changed, 23 insertions(+), 8 deletions(-) diff --git a/scripts/maint/practracker/exceptions.txt b/scripts/maint/practracker/exceptions.txt index a9fcf9095a..7b06683eb7 100644 --- a/scripts/maint/practracker/exceptions.txt +++ b/scripts/maint/practracker/exceptions.txt @@ -67,7 +67,7 @@ problem function-size /src/core/mainloop/connection.c:connection_handle_read_imp problem function-size /src/core/mainloop/connection.c:connection_buf_read_from_socket() 177 problem function-size /src/core/mainloop/connection.c:connection_handle_write_impl() 241 problem function-size /src/core/mainloop/connection.c:assert_connection_ok() 143 -problem file-size /src/core/mainloop/mainloop.c 3076 +problem file-size /src/core/mainloop/mainloop.c 3071 problem include-count /src/core/mainloop/mainloop.c 68 problem function-size /src/core/mainloop/mainloop.c:conn_close_if_marked() 108 problem function-size /src/core/mainloop/mainloop.c:run_connection_housekeeping() 123 @@ -276,7 +276,7 @@ problem function-size /src/lib/net/resolve.c:tor_addr_lookup() 110 problem function-size /src/lib/net/socketpair.c:tor_ersatz_socketpair() 102 problem function-size /src/lib/osinfo/uname.c:get_uname() 116 problem function-size /src/lib/process/process_unix.c:process_unix_exec() 220 -problem function-size /src/lib/process/process_win32.c:process_win32_exec() 138 +problem function-size /src/lib/process/process_win32.c:process_win32_exec() 133 problem function-size /src/lib/process/process_win32.c:process_win32_create_pipe() 112 problem function-size /src/lib/process/restrict.c:set_max_file_descriptors() 102 problem function-size /src/lib/process/setuid.c:switch_id() 156 diff --git a/src/core/mainloop/mainloop.c b/src/core/mainloop/mainloop.c index fd711fd3bc..e845ff416e 100644 --- a/src/core/mainloop/mainloop.c +++ b/src/core/mainloop/mainloop.c @@ -2595,12 +2595,7 @@ static int set_bridge_running_callback(time_t now, const or_options_t *options) { if (authdir_mode_bridge(options)) { - routerlist_t *rl = router_get_routerlist(); - - SMARTLIST_FOREACH_BEGIN(rl->routers, routerinfo_t *, ri) { - if (ri->purpose == ROUTER_PURPOSE_BRIDGE) - dirserv_set_router_is_running(ri, now); - } SMARTLIST_FOREACH_END(ri); + dirserv_set_bridges_running(now); #define SET_BRIDGES_RUNNING_INTERVAL (5*60) return SET_BRIDGES_RUNNING_INTERVAL; diff --git a/src/feature/dirauth/voteflags.c b/src/feature/dirauth/voteflags.c index 0a53c588d6..4040f162fa 100644 --- a/src/feature/dirauth/voteflags.c +++ b/src/feature/dirauth/voteflags.c @@ -29,6 +29,7 @@ #include "feature/nodelist/node_st.h" #include "feature/nodelist/routerinfo_st.h" +#include "feature/nodelist/routerlist_st.h" #include "feature/nodelist/vote_routerstatus_st.h" #include "lib/container/order.h" @@ -658,3 +659,20 @@ dirserv_set_routerstatus_testing(routerstatus_t *rs) rs->is_hs_dir = 0; } } + +/** Use dirserv_set_router_is_running() to set bridges as running if they're + * reachable. + * + * This function is called from set_bridge_running_callback() when running as + * a bridge authority. + */ +void +dirserv_set_bridges_running(time_t now) +{ + routerlist_t *rl = router_get_routerlist(); + + SMARTLIST_FOREACH_BEGIN(rl->routers, routerinfo_t *, ri) { + if (ri->purpose == ROUTER_PURPOSE_BRIDGE) + dirserv_set_router_is_running(ri, now); + } SMARTLIST_FOREACH_END(ri); +} diff --git a/src/feature/dirauth/voteflags.h b/src/feature/dirauth/voteflags.h index cca6f53746..18b29a5183 100644 --- a/src/feature/dirauth/voteflags.h +++ b/src/feature/dirauth/voteflags.h @@ -25,6 +25,8 @@ void set_routerstatus_from_routerinfo(routerstatus_t *rs, void dirserv_compute_performance_thresholds(digestmap_t *omit_as_sybil); +void dirserv_set_bridges_running(time_t now); + #ifdef VOTEFLAGS_PRIVATE /** Any descriptor older than this age causes the authorities to set the * StaleDesc flag. */ From c07d854772bda558ef8cf4fd71f2673c7ed00083 Mon Sep 17 00:00:00 2001 From: Neel Chauhan Date: Thu, 11 Apr 2019 21:28:35 -0400 Subject: [PATCH 06/10] Remove callback for setting bridges as running --- changes/bug24490 | 2 +- scripts/maint/practracker/exceptions.txt | 8 ++++---- src/core/mainloop/mainloop.c | 20 -------------------- src/feature/nodelist/networkstatus.c | 5 ++++- 4 files changed, 9 insertions(+), 26 deletions(-) diff --git a/changes/bug24490 b/changes/bug24490 index 1167e9f8d3..cf9281c878 100644 --- a/changes/bug24490 +++ b/changes/bug24490 @@ -1,5 +1,5 @@ o Minor bugfixes (bridge authority): - - We set bridges as running in a callback which runs every 5 minutes. + - We set bridges as running when we dump the bridge status to a file. Previously, we set bridges as running in a GETINFO controller, but these shouldn't modify vital data structures. Fixes bug 24490; bugfix on 0.2.0.13-alpha. Patch by Neel Chauhan diff --git a/scripts/maint/practracker/exceptions.txt b/scripts/maint/practracker/exceptions.txt index 7b06683eb7..ad5d3e9725 100644 --- a/scripts/maint/practracker/exceptions.txt +++ b/scripts/maint/practracker/exceptions.txt @@ -67,11 +67,11 @@ problem function-size /src/core/mainloop/connection.c:connection_handle_read_imp problem function-size /src/core/mainloop/connection.c:connection_buf_read_from_socket() 177 problem function-size /src/core/mainloop/connection.c:connection_handle_write_impl() 241 problem function-size /src/core/mainloop/connection.c:assert_connection_ok() 143 -problem file-size /src/core/mainloop/mainloop.c 3071 -problem include-count /src/core/mainloop/mainloop.c 68 +problem file-size /src/core/mainloop/mainloop.c 3051 +problem include-count /src/core/mainloop/mainloop.c 66 problem function-size /src/core/mainloop/mainloop.c:conn_close_if_marked() 108 problem function-size /src/core/mainloop/mainloop.c:run_connection_housekeeping() 123 -problem function-size /src/core/mainloop/mainloop.c:CALLBACK() 118 +problem function-size /src/core/mainloop/mainloop.c:CALLBACK() 116 problem file-size /src/core/or/channel.c 3476 problem function-size /src/core/or/channeltls.c:channel_tls_handle_var_cell() 160 problem function-size /src/core/or/channeltls.c:channel_tls_process_versions_cell() 170 @@ -276,7 +276,7 @@ problem function-size /src/lib/net/resolve.c:tor_addr_lookup() 110 problem function-size /src/lib/net/socketpair.c:tor_ersatz_socketpair() 102 problem function-size /src/lib/osinfo/uname.c:get_uname() 116 problem function-size /src/lib/process/process_unix.c:process_unix_exec() 220 -problem function-size /src/lib/process/process_win32.c:process_win32_exec() 133 +problem function-size /src/lib/process/process_win32.c:process_win32_exec() 138 problem function-size /src/lib/process/process_win32.c:process_win32_create_pipe() 112 problem function-size /src/lib/process/restrict.c:set_max_file_descriptors() 102 problem function-size /src/lib/process/setuid.c:switch_id() 156 diff --git a/src/core/mainloop/mainloop.c b/src/core/mainloop/mainloop.c index e845ff416e..c9f2b0d896 100644 --- a/src/core/mainloop/mainloop.c +++ b/src/core/mainloop/mainloop.c @@ -76,7 +76,6 @@ #include "feature/control/control_events.h" #include "feature/dirauth/authmode.h" #include "feature/dirauth/reachability.h" -#include "feature/dirauth/voteflags.h" #include "feature/dircache/consdiffmgr.h" #include "feature/dircache/dirserv.h" #include "feature/dircommon/directory.h" @@ -88,7 +87,6 @@ #include "feature/nodelist/networkstatus.h" #include "feature/nodelist/nodelist.h" #include "feature/nodelist/routerlist.h" -#include "feature/nodelist/routerlist_st.h" #include "feature/relay/dns.h" #include "feature/relay/routerkeys.h" #include "feature/relay/routermode.h" @@ -1377,7 +1375,6 @@ CALLBACK(rotate_onion_key); CALLBACK(rotate_x509_certificate); CALLBACK(save_stability); CALLBACK(save_state); -CALLBACK(set_bridge_running); CALLBACK(write_bridge_ns); CALLBACK(write_stats_file); CALLBACK(control_per_second_events); @@ -1456,7 +1453,6 @@ STATIC periodic_event_item_t periodic_events[] = { /* Bridge Authority only. */ CALLBACK(write_bridge_ns, BRIDGEAUTH, 0), - CALLBACK(set_bridge_running, BRIDGEAUTH, 0), /* Directory server only. */ CALLBACK(clean_consdiffmgr, DIRSERVER, 0), @@ -2587,22 +2583,6 @@ write_bridge_ns_callback(time_t now, const or_options_t *options) return PERIODIC_EVENT_NO_UPDATE; } -/** - * Periodic callback: if we're the bridge authority, set the running flag on - * bridges if they're reachable - */ -static int -set_bridge_running_callback(time_t now, const or_options_t *options) -{ - if (authdir_mode_bridge(options)) { - dirserv_set_bridges_running(now); - -#define SET_BRIDGES_RUNNING_INTERVAL (5*60) - return SET_BRIDGES_RUNNING_INTERVAL; - } - return PERIODIC_EVENT_NO_UPDATE; -} - static int heartbeat_callback_first_time = 1; /** diff --git a/src/feature/nodelist/networkstatus.c b/src/feature/nodelist/networkstatus.c index bc12fa4075..20881112aa 100644 --- a/src/feature/nodelist/networkstatus.c +++ b/src/feature/nodelist/networkstatus.c @@ -2409,7 +2409,7 @@ networkstatus_getinfo_by_purpose(const char *purpose_string, time_t now) void networkstatus_dump_bridge_status_to_file(time_t now) { - char *status = networkstatus_getinfo_by_purpose("bridge", now); + char *status; char *fname = NULL; char *thresholds = NULL; char *published_thresholds_and_status = NULL; @@ -2418,6 +2418,9 @@ networkstatus_dump_bridge_status_to_file(time_t now) char fingerprint[FINGERPRINT_LEN+1]; char *fingerprint_line = NULL; + dirserv_set_bridges_running(now); + status = networkstatus_getinfo_by_purpose("bridge", now); + if (me && crypto_pk_get_fingerprint(me->identity_pkey, fingerprint, 0) >= 0) { tor_asprintf(&fingerprint_line, "fingerprint %s\n", fingerprint); From 14d700804568ef5624856976b723eafab9e41972 Mon Sep 17 00:00:00 2001 From: Neel Chauhan Date: Thu, 11 Apr 2019 21:30:48 -0400 Subject: [PATCH 07/10] Stop setting routers as running in list_server_status_v1() --- src/feature/control/fmt_serverstatus.c | 5 +---- 1 file changed, 1 insertion(+), 4 deletions(-) diff --git a/src/feature/control/fmt_serverstatus.c b/src/feature/control/fmt_serverstatus.c index a1ddd2119a..fc1029ae84 100644 --- a/src/feature/control/fmt_serverstatus.c +++ b/src/feature/control/fmt_serverstatus.c @@ -78,10 +78,7 @@ list_server_status_v1(smartlist_t *routers, char **router_status_out, SMARTLIST_FOREACH_BEGIN(routers, routerinfo_t *, ri) { const node_t *node = node_get_by_id(ri->cache_info.identity_digest); tor_assert(node); - if (authdir) { - /* Update router status in routerinfo_t. */ - dirserv_set_router_is_running(ri, now); - } + if (for_controller) { char name_buf[MAX_VERBOSE_NICKNAME_LEN+2]; char *cp = name_buf; From 994b8ba424e0e225b3a3b3923044ff900cedfc12 Mon Sep 17 00:00:00 2001 From: Neel Chauhan Date: Thu, 11 Apr 2019 21:36:38 -0400 Subject: [PATCH 08/10] Update networkstatus_getinfo_by_purpose() comment --- src/feature/nodelist/networkstatus.c | 3 ++- 1 file changed, 2 insertions(+), 1 deletion(-) diff --git a/src/feature/nodelist/networkstatus.c b/src/feature/nodelist/networkstatus.c index 20881112aa..db510c975b 100644 --- a/src/feature/nodelist/networkstatus.c +++ b/src/feature/nodelist/networkstatus.c @@ -2405,7 +2405,8 @@ networkstatus_getinfo_by_purpose(const char *purpose_string, time_t now) return answer; } -/** Write out router status entries for all our bridge descriptors. */ +/** Write out router status entries for all our bridge descriptors. Here, we + * also mark routers as running. */ void networkstatus_dump_bridge_status_to_file(time_t now) { From 398c736230719e6b8eb539c7b08a5acfc0463db1 Mon Sep 17 00:00:00 2001 From: Neel Chauhan Date: Thu, 11 Apr 2019 22:11:27 -0400 Subject: [PATCH 09/10] Remove unused variable in fmt_serverstatus.c --- src/feature/control/fmt_serverstatus.c | 1 - 1 file changed, 1 deletion(-) diff --git a/src/feature/control/fmt_serverstatus.c b/src/feature/control/fmt_serverstatus.c index fc1029ae84..1fc5d4a157 100644 --- a/src/feature/control/fmt_serverstatus.c +++ b/src/feature/control/fmt_serverstatus.c @@ -70,7 +70,6 @@ list_server_status_v1(smartlist_t *routers, char **router_status_out, /* We include v2 dir auths here too, because they need to answer * controllers. Eventually we'll deprecate this whole function; * see also networkstatus_getinfo_by_purpose(). */ - int authdir = authdir_mode_publishes_statuses(options); tor_assert(router_status_out); rs_entries = smartlist_new(); From cc87acf29b40a135745f74412caaececf8ea0329 Mon Sep 17 00:00:00 2001 From: Neel Chauhan Date: Sun, 14 Apr 2019 14:51:42 -0400 Subject: [PATCH 10/10] Remove unused get_options() --- src/feature/control/fmt_serverstatus.c | 1 - 1 file changed, 1 deletion(-) diff --git a/src/feature/control/fmt_serverstatus.c b/src/feature/control/fmt_serverstatus.c index 1fc5d4a157..d224a1d234 100644 --- a/src/feature/control/fmt_serverstatus.c +++ b/src/feature/control/fmt_serverstatus.c @@ -66,7 +66,6 @@ list_server_status_v1(smartlist_t *routers, char **router_status_out, smartlist_t *rs_entries; time_t now = time(NULL); time_t cutoff = now - ROUTER_MAX_AGE_TO_PUBLISH; - const or_options_t *options = get_options(); /* We include v2 dir auths here too, because they need to answer * controllers. Eventually we'll deprecate this whole function; * see also networkstatus_getinfo_by_purpose(). */