Skip to content
Snippets Groups Projects
Commit 8b5d95db authored by Nick Mathewson's avatar Nick Mathewson :game_die:
Browse files

Fix test.c compilation on mingw32.

Looks like windows doesn't have an s6_addr32 in its in6_addr.

Bug not in any released version of Tor; bugfix on abb88601.
parent 08436b27
Branches
Tags
No related merge requests found
......@@ -1547,7 +1547,10 @@ test_geoip(void)
memset(&in6, 0, sizeof(in6));
/* Make sure that country ID actually works. */
#define SET_TEST_IPV6(i) in6.s6_addr32[3] = htonl((uint32_t) i)
#define SET_TEST_IPV6(i) \
do { \
set_uint32(in6.s6_addr + 12, htonl((uint32_t) (i))); \
} while (0)
#define CHECK_COUNTRY(country, val) do { \
/* test ipv4 country lookup */ \
test_streq(country, \
......
0% Loading or .
You are about to add 0 people to the discussion. Proceed with caution.
Please register or to comment