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

[tor-commits] [arm/release] fix: loop from closing conn based on torctl event



commit e272d05973abcc3b92acecb4e944c8861ed58903
Author: Damian Johnson <atagar@xxxxxxxxxxxxxx>
Date:   Mon Jun 13 20:35:56 2011 -0700

    fix: loop from closing conn based on torctl event
    
    Attempting to close our control connection when TorCtl logged a message
    saying that it was done caused us to attempt to join our own thread within
    torctl (which causes an exception).
    
    I'm not really recalling why I ever did this, but fixes for concurrency issues
    in TorCtl are triggering this so removing the check.
---
 src/util/torTools.py |    4 ----
 1 files changed, 0 insertions(+), 4 deletions(-)

diff --git a/src/util/torTools.py b/src/util/torTools.py
index f17ed0b..a4c0b5d 100644
--- a/src/util/torTools.py
+++ b/src/util/torTools.py
@@ -67,7 +67,6 @@ CACHE_GETINFO_PREFIX_ARGS = ("ip-to-country/", )
 # so erring on the side of inclusiveness by using the notice event instead.
 ADDR_CHANGED_MSG_PREFIX = ("Our IP Address has changed from", "Guessed our IP address as")
 
-TOR_CTL_CLOSE_MSG = "Tor closed control connection. Exiting event thread."
 UNKNOWN = "UNKNOWN" # value used by cached information if undefined
 CONFIG = {"torrc.map": {},
           "features.pathPrefix": "",
@@ -1605,9 +1604,6 @@ class Controller(TorCtl.PostEventListener):
     # notifies listeners of TorCtl events
     for callback in self.torctlListeners: callback(TORCTL_RUNLEVELS[level], msg)
     
-    # checks if TorCtl is providing a notice that control port is closed
-    if TOR_CTL_CLOSE_MSG in msg: self.close()
-    
     # if the message is informing us of our ip address changing then clear
     # its cached value
     for prefix in ADDR_CHANGED_MSG_PREFIX:



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