diff options
-rw-r--r-- | src/test/test_dns.c | 16 |
1 files changed, 16 insertions, 0 deletions
diff --git a/src/test/test_dns.c b/src/test/test_dns.c index 6ba9cf4e50..b40a4825a6 100644 --- a/src/test/test_dns.c +++ b/src/test/test_dns.c @@ -355,6 +355,8 @@ NS(test_main)(void *arg) const tor_addr_t *resolved_addr; tor_addr_t addr_to_compare; + (void)arg; + tor_addr_parse(&addr_to_compare, "8.8.8.8"); or_circuit_t *on_circ = tor_malloc_zero(sizeof(or_circuit_t)); @@ -401,6 +403,8 @@ NS(test_main)(void *arg) edge_connection_t *exitconn = create_valid_exitconn(); or_circuit_t *on_circ = tor_malloc_zero(sizeof(or_circuit_t)); + (void)arg; + TO_CONN(exitconn)->address = tor_strdup("torproject.org"); NS_MOCK(router_my_exit_policy_is_reject_star); @@ -442,6 +446,8 @@ NS(test_main)(void *arg) edge_connection_t *exitconn = create_valid_exitconn(); or_circuit_t *on_circ = tor_malloc_zero(sizeof(or_circuit_t)); + (void)arg; + NS_MOCK(router_my_exit_policy_is_reject_star); TO_CONN(exitconn)->address = tor_strdup("invalid#@!.org"); @@ -482,6 +488,8 @@ NS(test_main)(void *arg) edge_connection_t *exitconn = create_valid_exitconn(); or_circuit_t *on_circ = tor_malloc_zero(sizeof(or_circuit_t)); + (void)arg; + TO_CONN(exitconn)->address = tor_strdup("127.0.0.1.in-addr.arpa"); NS_MOCK(router_my_exit_policy_is_reject_star); @@ -541,6 +549,8 @@ NS(test_main)(void *arg) cache_entry->minheap_idx = -1; cache_entry->expire = time(NULL) + 60 * 60; + (void)arg; + TO_CONN(exitconn)->address = tor_strdup("torproject.org"); strlcpy(cache_entry->address, TO_CONN(exitconn)->address, @@ -597,6 +607,8 @@ NS(set_exitconn_info_from_resolve)(edge_connection_t *exitconn, last_exitconn = exitconn; last_resolve = (cached_resolve_t *)resolve; + (void)hostname_out; + return 0; } @@ -617,6 +629,8 @@ NS(test_main)(void *arg) cache_entry->minheap_idx = -1; cache_entry->expire = time(NULL) + 60 * 60; + (void)arg; + TO_CONN(exitconn)->address = tor_strdup("torproject.org"); strlcpy(cache_entry->address, TO_CONN(exitconn)->address, @@ -689,6 +703,8 @@ NS(test_main)(void *arg) cached_resolve_t *cache_entry = NULL; cached_resolve_t query; + (void)arg; + TO_CONN(exitconn)->address = tor_strdup("torproject.org"); strlcpy(query.address, TO_CONN(exitconn)->address, sizeof(query.address)); |