]> git.ipfire.org Git - thirdparty/tor.git/commitdiff
r15621@catbus: nickm | 2007-10-10 00:37:25 -0400
authorNick Mathewson <nickm@torproject.org>
Wed, 10 Oct 2007 04:37:38 +0000 (04:37 +0000)
committerNick Mathewson <nickm@torproject.org>
Wed, 10 Oct 2007 04:37:38 +0000 (04:37 +0000)
 Turns out, Bug 463 was just another "warn about something that is no big deal" thing. Downgrade, comment, and resolve.

svn:r11829

ChangeLog
src/or/dns.c

index 22fada7389bab2e93c54ec5a97ccb55cc06ea45c..3d2660c352fc66734da1927228594a7107a09e1e 100644 (file)
--- a/ChangeLog
+++ b/ChangeLog
@@ -55,6 +55,11 @@ Changes in version 0.2.0.8-alpha - 2007-??-??
     - On some platforms, accept() can return a broken address.  Detect
       this more quietly, and deal accordingly.  (Fixes bug 483.)
 
+  o Minor bugfixes (DNS):
+    - It's not actually an error to find a non-pending entry in the DNS
+      cache when canceling a pending resolve.  Don't log unless stuff
+      is fishy.  Resolves bug 463.
+
   o Code simplifications and refactoring:
     - Make a bunch of functions static.  Remove some dead code.
     - Pull out about a third of the really big routerlist.c; put it in a
index 64cfcb024e7f49d9ecffaae7e9bb561d6777bf63..7c52d56f856a4f85c0a85417e06a231e3548928f 100644 (file)
@@ -836,8 +836,15 @@ dns_cancel_pending_resolve(const char *address)
     return;
 
   if (resolve->state != CACHE_STATE_PENDING) {
-    log_notice(LD_BUG,"Address %s is not pending (state %d). Dropping.",
-               escaped_safe_str(address), resolve->state);
+    /* We can get into this state if we never actually created the pending
+     * resolve, due to finding an earlier cached error or something.  Just
+     * ignore it. */
+    if (resolve->pending_connections) {
+      log_warn(LD_BUG,
+               "Address %s is not pending but has pending connections!",
+               escaped_safe_str(address));
+      tor_fragile_assert();
+    }
     return;
   }