Skip to content

HTTPS clone URL

Subversion checkout URL

You can clone with HTTPS or Subversion.

Download ZIP
Browse files

fixed incompatibility with older versions of twisted introduced with …

…memory leak fix
  • Loading branch information...
commit 27de695afc01ad16bb534cc2a6777b8d338c3638 1 parent 6ff320b
@forrestv authored
Showing with 2 additions and 2 deletions.
  1. +2 −2 p2pool/p2p.py
View
4 p2pool/p2p.py
@@ -80,7 +80,7 @@ def connectionMade(self):
def _connect_timeout(self):
self.timeout_delayed = None
print 'Handshake timed out, disconnecting from %s:%i' % self.addr
- if self.transport.abortConnection is not None:
+ if hasattr(self.transport, 'abortConnection'):
# Available since Twisted 11.1
self.transport.abortConnection()
else:
@@ -106,7 +106,7 @@ def badPeerHappened(self):
def _timeout(self):
self.timeout_delayed = None
print 'Connection timed out, disconnecting from %s:%i' % self.addr
- if self.transport.abortConnection is not None:
+ if hasattr(self.transport, 'abortConnection'):
# Available since Twisted 11.1
self.transport.abortConnection()
else:
Please sign in to comment.
Something went wrong with that request. Please try again.