aboutsummaryrefslogtreecommitdiff
path: root/rpkid
diff options
context:
space:
mode:
authorRob Austein <sra@hactrn.net>2010-01-24 16:13:02 +0000
committerRob Austein <sra@hactrn.net>2010-01-24 16:13:02 +0000
commit963d2c9760d0cb5531c495884ab2161a6251045b (patch)
tree09fc9f0565dab0e745295efe10499483b7a15a80 /rpkid
parentd8465a323f83c3694675c4d79ccce39d8aa642f2 (diff)
Get rid of spurious connection timeout messages (helps to cancel the
timer when closing the connection, doh). svn path=/rpkid/rpki/https.py; revision=2972
Diffstat (limited to 'rpkid')
-rw-r--r--rpkid/rpki/https.py9
1 files changed, 4 insertions, 5 deletions
diff --git a/rpkid/rpki/https.py b/rpkid/rpki/https.py
index 03d0f6d5..26b1cd87 100644
--- a/rpkid/rpki/https.py
+++ b/rpkid/rpki/https.py
@@ -279,8 +279,6 @@ class http_stream(asynchat.async_chat):
def handle_close(self):
self.log("Close event in HTTP stream handler")
- self.timer.cancel()
- self.timer.set_handler(None)
asynchat.async_chat.handle_close(self)
def send(self, data):
@@ -371,12 +369,13 @@ class http_stream(asynchat.async_chat):
except POW.WantWriteError:
self.retry_write = self.close
except POW.SSLError, e:
- self.log("socket shutdown threw %s, shutting down anyway" % e)
+ self.log("tls.shutdown() threw %s, shutting down anyway" % e)
self.tls = None
if self.tls is None:
- self.log("TLS layer is done, closing underlying socket %r (connected %s accepting %s)" % (self.socket, self.connected, self.accepting))
+ self.log("TLS layer is done, closing socket")
+ self.timer.cancel()
+ self.timer.set_handler(None)
asynchat.async_chat.close(self)
- self.log("Closed underlying socket %r (connected %s accepting %s)" % (self.socket, self.connected, self.accepting))
def log_cert(self, tag, x):
if debug_tls_certs: