From 2092b5d936acd1b69269ace0d22e862790ad57b3 Mon Sep 17 00:00:00 2001 From: "Coren[m]" Date: Sun, 15 Sep 2013 08:20:37 +0200 Subject: addr_resolve() rewrite broke { (ipv6enabled == true) name => IPv4 address } network.c: - addr_resolve(): save AF_UNSPEC ip4 address into ip4, not into to->ip4 --- toxcore/network.c | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) (limited to 'toxcore') diff --git a/toxcore/network.c b/toxcore/network.c index 6ae13160..83081a49 100644 --- a/toxcore/network.c +++ b/toxcore/network.c @@ -744,7 +744,7 @@ int addr_resolve(const char *address, IP *to, IP *extra) #ifdef TOX_ENABLE_IPV6 else if (!(rc & 1)) { struct sockaddr_in *addr = (struct sockaddr_in *)walker->ai_addr; - to->ip4.in_addr = addr->sin_addr; + ip4.in_addr = addr->sin_addr; rc |= 1; } #endif -- cgit v1.2.3