aboutsummaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorNick Mathewson <nickm@torproject.org>2008-02-26 19:27:39 +0000
committerNick Mathewson <nickm@torproject.org>2008-02-26 19:27:39 +0000
commit564028a07d86e7160750fb5703ab5107fa72efa8 (patch)
tree8c5090a89750f206bb3259ec1e95ba4482ddbb77
parentc9c7f3c892fd0cfcf86b7cc1864584a0f06b14a0 (diff)
downloadtor-564028a07d86e7160750fb5703ab5107fa72efa8.tar.gz
tor-564028a07d86e7160750fb5703ab5107fa72efa8.zip
r14472@tombo: nickm | 2008-02-26 13:44:08 -0500
Backport trivial fix for problem that kept nameserver errors from getting reported. svn:r13741
-rw-r--r--ChangeLog1
-rw-r--r--src/or/dns.c2
2 files changed, 2 insertions, 1 deletions
diff --git a/ChangeLog b/ChangeLog
index c841bfe4ae..5d3bc5a2d5 100644
--- a/ChangeLog
+++ b/ChangeLog
@@ -20,6 +20,7 @@ Changes in versino 0.1.2.20 - 2008-??-??
- We were leaking a file descriptor if Tor started with a zero-length
cached-descriptors file. Patch by freddy77.
- Detect size overflow in zlib code.
+ - Fix a pointer error that kept us from reporting nameserver errors.
Changes in version 0.1.2.19 - 2008-01-17
diff --git a/src/or/dns.c b/src/or/dns.c
index 977943ebe4..2a8f50efd7 100644
--- a/src/or/dns.c
+++ b/src/or/dns.c
@@ -185,7 +185,7 @@ evdns_log_cb(int warn, const char *msg)
}
if (!strcmpstart(msg, "Nameserver ") && (cp=strstr(msg, " has failed: "))) {
char *ns = tor_strndup(msg+11, cp-(msg+11));
- const char *err = strchr(cp, ':'+2);
+ const char *err = strchr(cp, ':')+2;
/* Don't warn about a single failed nameserver; we'll warn with 'all
* nameservers have failed' if we're completely out of nameservers;
* otherwise, the situation is tolerable. */