Commit f1afd93d authored by Luke Macken's avatar Luke Macken

Add some additional debugging to the ipc socket code

parent ce4cbbca
......@@ -80,17 +80,21 @@ class PyrasiteIPC(object):
af, socktype, proto, canonname, sa = res
try:
self.server_sock = socket.socket(af, socktype, proto)
except socket.error:
except socket.error, e:
log.debug(str(e))
self.server_sock = None
continue
try:
self.server_sock.bind(sa)
self.server_sock.listen(1)
except socket.error:
except socket.error, e:
log.debug(str(e))
self.server_sock.close()
self.server_sock = None
continue
break
else:
log.error('Unable to setup server socket')
self.hostname, self.port = self.server_sock.getsockname()[0:2]
self.running = True
......
Markdown is supported
0%
or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment