aboutsummaryrefslogtreecommitdiff
diff options
context:
space:
mode:
-rw-r--r--changes/bug25742
-rw-r--r--src/or/eventdns.c2
2 files changed, 3 insertions, 1 deletions
diff --git a/changes/bug2574 b/changes/bug2574
new file mode 100644
index 0000000000..32f4ae4a92
--- /dev/null
+++ b/changes/bug2574
@@ -0,0 +1,2 @@
+ o Minor features:
+ - Allow nameserves with IPv6 address. Fixes bug 2574.
diff --git a/src/or/eventdns.c b/src/or/eventdns.c
index 725b59a19e..0a0fef43f3 100644
--- a/src/or/eventdns.c
+++ b/src/or/eventdns.c
@@ -2291,7 +2291,7 @@ _evdns_nameserver_add_impl(const struct sockaddr *address,
evtimer_set(&ns->timeout_event, nameserver_prod_callback, ns);
- ns->socket = tor_open_socket(PF_INET, SOCK_DGRAM, 0);
+ ns->socket = tor_open_socket(address->sa_family, SOCK_DGRAM, 0);
if (ns->socket < 0) { err = 1; goto out1; }
#ifdef WIN32
{