Loading src/core/or/circuituse.c +2 −1 Original line number Diff line number Diff line Loading @@ -1659,7 +1659,8 @@ static void circuit_testing_failed(origin_circuit_t *circ, int at_last_hop) { const or_options_t *options = get_options(); if (server_mode(options) && router_should_skip_orport_reachability_check(options)) if (server_mode(options) && router_should_skip_orport_reachability_check(options)) return; log_info(LD_GENERAL, Loading src/feature/control/control_getinfo.c +10 −7 Original line number Diff line number Diff line Loading @@ -1276,13 +1276,16 @@ getinfo_helper_events(control_connection_t *control_conn, *answer = tor_strdup(directories_have_accepted_server_descriptor() ? "1" : "0"); } else if (!strcmp(question, "status/reachability-succeeded/or")) { *answer = tor_strdup(router_should_skip_orport_reachability_check(options) ? *answer = tor_strdup( router_should_skip_orport_reachability_check(options) ? "1" : "0"); } else if (!strcmp(question, "status/reachability-succeeded/dir")) { *answer = tor_strdup(router_should_skip_dirport_reachability_check(options) ? *answer = tor_strdup( router_should_skip_dirport_reachability_check(options) ? "1" : "0"); } else if (!strcmp(question, "status/reachability-succeeded")) { tor_asprintf(answer, "OR=%d DIR=%d", tor_asprintf( answer, "OR=%d DIR=%d", router_should_skip_orport_reachability_check(options) ? 1 : 0, router_should_skip_dirport_reachability_check(options) ? 1 : 0); } else if (!strcmp(question, "status/bootstrap-phase")) { Loading src/feature/nodelist/node_select.c +10 −6 Original line number Diff line number Diff line Loading @@ -321,9 +321,11 @@ router_pick_directory_server_impl(dirinfo_type_t type, int flags, overloaded_direct = smartlist_new(); overloaded_tunnel = smartlist_new(); const int skip_or_fw = client_or_conn_should_skip_reachable_address_check(options, const int skip_or_fw = client_or_conn_should_skip_reachable_address_check( options, try_ip_pref); const int skip_dir_fw = client_dir_conn_should_skip_reachable_address_check(options, const int skip_dir_fw = client_dir_conn_should_skip_reachable_address_check( options, try_ip_pref); const int must_have_or = dirclient_must_use_begindir(options); Loading Loading @@ -1122,9 +1124,11 @@ router_pick_trusteddirserver_impl(const smartlist_t *sourcelist, overloaded_direct = smartlist_new(); overloaded_tunnel = smartlist_new(); const int skip_or_fw = client_or_conn_should_skip_reachable_address_check(options, const int skip_or_fw = client_or_conn_should_skip_reachable_address_check( options, try_ip_pref); const int skip_dir_fw = client_dir_conn_should_skip_reachable_address_check(options, const int skip_dir_fw = client_dir_conn_should_skip_reachable_address_check( options, try_ip_pref); const int must_have_or = dirclient_must_use_begindir(options); Loading src/feature/nodelist/routerlist.c +6 −3 Original line number Diff line number Diff line Loading @@ -476,7 +476,8 @@ router_reload_router_list(void) * Finally, return true if ReachableAddresses is set. */ int client_or_conn_should_skip_reachable_address_check(const or_options_t *options, client_or_conn_should_skip_reachable_address_check( const or_options_t *options, int try_ip_pref) { /* Servers always have and prefer IPv4. Loading @@ -491,7 +492,8 @@ client_or_conn_should_skip_reachable_address_check(const or_options_t *options, * This function is obsolete, because clients only use ORPorts. */ int client_dir_conn_should_skip_reachable_address_check(const or_options_t *options, client_dir_conn_should_skip_reachable_address_check( const or_options_t *options, int try_ip_pref) { /* Servers always have and prefer IPv4. Loading @@ -518,7 +520,8 @@ router_add_running_nodes_to_smartlist(smartlist_t *sl, int need_uptime, int need_desc, int pref_addr, int direct_conn) { const int check_reach = !client_or_conn_should_skip_reachable_address_check(get_options(), const int check_reach = !client_or_conn_should_skip_reachable_address_check( get_options(), pref_addr); /* XXXX MOVE */ SMARTLIST_FOREACH_BEGIN(nodelist_get_list(), const node_t *, node) { Loading src/feature/nodelist/routerlist.h +5 −3 Original line number Diff line number Diff line Loading @@ -50,9 +50,11 @@ typedef enum was_router_added_t { int router_reload_router_list(void); int client_or_conn_should_skip_reachable_address_check(const or_options_t *options, int client_or_conn_should_skip_reachable_address_check( const or_options_t *options, int try_ip_pref); int client_dir_conn_should_skip_reachable_address_check(const or_options_t *options, int client_dir_conn_should_skip_reachable_address_check( const or_options_t *options, int try_ip_pref); void router_reset_status_download_failures(void); int routers_have_same_or_addrs(const routerinfo_t *r1, const routerinfo_t *r2); Loading Loading
src/core/or/circuituse.c +2 −1 Original line number Diff line number Diff line Loading @@ -1659,7 +1659,8 @@ static void circuit_testing_failed(origin_circuit_t *circ, int at_last_hop) { const or_options_t *options = get_options(); if (server_mode(options) && router_should_skip_orport_reachability_check(options)) if (server_mode(options) && router_should_skip_orport_reachability_check(options)) return; log_info(LD_GENERAL, Loading
src/feature/control/control_getinfo.c +10 −7 Original line number Diff line number Diff line Loading @@ -1276,13 +1276,16 @@ getinfo_helper_events(control_connection_t *control_conn, *answer = tor_strdup(directories_have_accepted_server_descriptor() ? "1" : "0"); } else if (!strcmp(question, "status/reachability-succeeded/or")) { *answer = tor_strdup(router_should_skip_orport_reachability_check(options) ? *answer = tor_strdup( router_should_skip_orport_reachability_check(options) ? "1" : "0"); } else if (!strcmp(question, "status/reachability-succeeded/dir")) { *answer = tor_strdup(router_should_skip_dirport_reachability_check(options) ? *answer = tor_strdup( router_should_skip_dirport_reachability_check(options) ? "1" : "0"); } else if (!strcmp(question, "status/reachability-succeeded")) { tor_asprintf(answer, "OR=%d DIR=%d", tor_asprintf( answer, "OR=%d DIR=%d", router_should_skip_orport_reachability_check(options) ? 1 : 0, router_should_skip_dirport_reachability_check(options) ? 1 : 0); } else if (!strcmp(question, "status/bootstrap-phase")) { Loading
src/feature/nodelist/node_select.c +10 −6 Original line number Diff line number Diff line Loading @@ -321,9 +321,11 @@ router_pick_directory_server_impl(dirinfo_type_t type, int flags, overloaded_direct = smartlist_new(); overloaded_tunnel = smartlist_new(); const int skip_or_fw = client_or_conn_should_skip_reachable_address_check(options, const int skip_or_fw = client_or_conn_should_skip_reachable_address_check( options, try_ip_pref); const int skip_dir_fw = client_dir_conn_should_skip_reachable_address_check(options, const int skip_dir_fw = client_dir_conn_should_skip_reachable_address_check( options, try_ip_pref); const int must_have_or = dirclient_must_use_begindir(options); Loading Loading @@ -1122,9 +1124,11 @@ router_pick_trusteddirserver_impl(const smartlist_t *sourcelist, overloaded_direct = smartlist_new(); overloaded_tunnel = smartlist_new(); const int skip_or_fw = client_or_conn_should_skip_reachable_address_check(options, const int skip_or_fw = client_or_conn_should_skip_reachable_address_check( options, try_ip_pref); const int skip_dir_fw = client_dir_conn_should_skip_reachable_address_check(options, const int skip_dir_fw = client_dir_conn_should_skip_reachable_address_check( options, try_ip_pref); const int must_have_or = dirclient_must_use_begindir(options); Loading
src/feature/nodelist/routerlist.c +6 −3 Original line number Diff line number Diff line Loading @@ -476,7 +476,8 @@ router_reload_router_list(void) * Finally, return true if ReachableAddresses is set. */ int client_or_conn_should_skip_reachable_address_check(const or_options_t *options, client_or_conn_should_skip_reachable_address_check( const or_options_t *options, int try_ip_pref) { /* Servers always have and prefer IPv4. Loading @@ -491,7 +492,8 @@ client_or_conn_should_skip_reachable_address_check(const or_options_t *options, * This function is obsolete, because clients only use ORPorts. */ int client_dir_conn_should_skip_reachable_address_check(const or_options_t *options, client_dir_conn_should_skip_reachable_address_check( const or_options_t *options, int try_ip_pref) { /* Servers always have and prefer IPv4. Loading @@ -518,7 +520,8 @@ router_add_running_nodes_to_smartlist(smartlist_t *sl, int need_uptime, int need_desc, int pref_addr, int direct_conn) { const int check_reach = !client_or_conn_should_skip_reachable_address_check(get_options(), const int check_reach = !client_or_conn_should_skip_reachable_address_check( get_options(), pref_addr); /* XXXX MOVE */ SMARTLIST_FOREACH_BEGIN(nodelist_get_list(), const node_t *, node) { Loading
src/feature/nodelist/routerlist.h +5 −3 Original line number Diff line number Diff line Loading @@ -50,9 +50,11 @@ typedef enum was_router_added_t { int router_reload_router_list(void); int client_or_conn_should_skip_reachable_address_check(const or_options_t *options, int client_or_conn_should_skip_reachable_address_check( const or_options_t *options, int try_ip_pref); int client_dir_conn_should_skip_reachable_address_check(const or_options_t *options, int client_dir_conn_should_skip_reachable_address_check( const or_options_t *options, int try_ip_pref); void router_reset_status_download_failures(void); int routers_have_same_or_addrs(const routerinfo_t *r1, const routerinfo_t *r2); Loading