Skip to content

Commit 2d9bea3

Browse files
committed
Changed try/catch to be py2.5 compatible
1 parent faa5a5b commit 2d9bea3

File tree

1 file changed

+2
-2
lines changed

1 file changed

+2
-2
lines changed

pssh.py

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -72,10 +72,10 @@ def _connect(self):
7272
"""Connect to host, throw UnknownHost exception on DNS errors"""
7373
try:
7474
self.client.connect(self.host, username = self.user)
75-
except socket.gaierror as e:
75+
except socket.gaierror, e:
7676
logger.error("Could not resolve host %s" % (self.host,))
7777
raise UnknownHostException("%s - %s" % (str(e.strerror), self.host,))
78-
except socket.error as e:
78+
except socket.error, e:
7979
logger.error("Error connecting to host %s" % (self.host,))
8080
raise ConnectionErrorException("%s for host '%s'" % (str(e.strerror), self.host,))
8181

0 commit comments

Comments
 (0)