[Author Prev][Author Next][Thread Prev][Thread Next][Author Index][Thread Index]

[tor-commits] [tor/release-0.2.1] Fix a bug in removing DNSPort requests from their circular list



commit e98583594d897ac32745061143e565c6f4b45f97
Author: Nick Mathewson <nickm@xxxxxxxxxxxxxx>
Date:   Thu Apr 21 13:39:00 2011 -0400

    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.
---
 changes/bug2933   |    4 ++++
 src/or/eventdns.c |    2 +-
 2 files changed, 5 insertions(+), 1 deletions(-)

diff --git a/changes/bug2933 b/changes/bug2933
new file mode 100644
index 0000000..7aaf526
--- /dev/null
+++ b/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.
+
diff --git a/src/or/eventdns.c b/src/or/eventdns.c
index a889e80..2777f90 100644
--- a/src/or/eventdns.c
+++ b/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;



_______________________________________________
tor-commits mailing list
tor-commits@xxxxxxxxxxxxxxxxxxxx
https://lists.torproject.org/cgi-bin/mailman/listinfo/tor-commits