From: Nick Mathewson Date: Wed, 10 Dec 2008 22:57:41 +0000 (+0000) Subject: Fix a logic error that would automatically reject all but the first configured DNS... X-Git-Tag: tor-0.2.1.9-alpha~132 X-Git-Url: http://git.ipfire.org/gitweb.cgi?a=commitdiff_plain;h=d8027aa6898116436d591958407bf85b652c1253;p=thirdparty%2Ftor.git Fix a logic error that would automatically reject all but the first configured DNS server. Bugfix on 0.2.1.5-alpha. Possible fix for part of 813/868. Spotted by coderman svn:r17569 --- diff --git a/ChangeLog b/ChangeLog index 1da3071574..6a361c2956 100644 --- a/ChangeLog +++ b/ChangeLog @@ -1,4 +1,9 @@ Changes in version 0.2.1.9-alpha - 200?-??-?? + o Major bugfixes: + - Fix a logic error that would automatically reject all but the first + configured DNS server. Bugfix on 0.2.1.5-alpha. Possible fix for part + of bug 813/868. Bug spotted by coderman. + o Minor features: - Give a better error message when an overzealous init script says, "sudo -u username tor --user username". Makes Bug 882 easier diff --git a/src/or/eventdns.c b/src/or/eventdns.c index 88ca1bbe91..cd5629bd1a 100644 --- a/src/or/eventdns.c +++ b/src/or/eventdns.c @@ -2224,7 +2224,7 @@ _evdns_nameserver_add_impl(const struct sockaddr *address, int err = 0; if (server) { do { - if (!sockaddr_eq(address, (struct sockaddr *)&server->address, 1)) { + if (sockaddr_eq(address, (struct sockaddr *)&server->address, 1)) { log(EVDNS_LOG_DEBUG, "Duplicate nameserver."); return 3; }