Browse Source

Fix a bug in removing DNSPort requests from their circular list

Under heavy load, this could result in an assertion failure.  Fix for
bug 2933; bugfix on 0.2.0.10-alpha.
Nick Mathewson 13 years ago
parent
commit
e98583594d
2 changed files with 5 additions and 1 deletions
  1. 4 0
      changes/bug2933
  2. 1 1
      src/or/eventdns.c

+ 4 - 0
changes/bug2933

@@ -0,0 +1,4 @@
+  o Minor bugfixes
+    - Fix an uncommon assertion failure when running with DNSPort under
+      heavy load.  Fixes bug 2933; bugfix on 2.0.1-alpha.
+

+ 1 - 1
src/or/eventdns.c

@@ -1949,7 +1949,7 @@ server_request_free(struct server_request *req)
 
 	if (req->port) {
 		if (req->port->pending_replies == req) {
-			if (req->next_pending)
+			if (req->next_pending && req->next_pending != req)
 				req->port->pending_replies = req->next_pending;
 			else
 				req->port->pending_replies = NULL;