diff options
author | elie <elie> | 2006-09-06 16:41:47 +0000 |
---|---|---|
committer | elie <elie> | 2006-09-06 16:41:47 +0000 |
commit | f4acbcf39ca9ced59e5e15ef3a41679fcd3f1ed0 (patch) | |
tree | 1ae199418e51dfe42a885649b178f2b5dfdb0562 /pysnmp/carrier/asyncore | |
parent | 44c43c3614343a7d53fa5e82a97dd2d08488c5e2 (diff) | |
download | pysnmp-git-f4acbcf39ca9ced59e5e15ef3a41679fcd3f1ed0.tar.gz |
debugging added
Diffstat (limited to 'pysnmp/carrier/asyncore')
-rw-r--r-- | pysnmp/carrier/asyncore/dgram/base.py | 5 |
1 files changed, 5 insertions, 0 deletions
diff --git a/pysnmp/carrier/asyncore/dgram/base.py b/pysnmp/carrier/asyncore/dgram/base.py index ee1a855a..feac664d 100644 --- a/pysnmp/carrier/asyncore/dgram/base.py +++ b/pysnmp/carrier/asyncore/dgram/base.py @@ -2,6 +2,7 @@ import socket, errno from pysnmp.carrier.asynsock.base import AbstractSocketTransport from pysnmp.carrier import error +from pysnmp import debug sockErrors = { errno.ESHUTDOWN: 1, @@ -47,10 +48,14 @@ class DgramSocketTransport(AbstractSocketTransport): except socket.error, why: if why[0] != errno.EWOULDBLOCK: raise socket.error, why + else: + debug.logger & debug.flagIO and debug.logger('handle_write: transportAddress %s outgoingMessage %s' % (transportAddress, repr(outgoingMessage))) + def readable(self): return 1 def handle_read(self): try: incomingMessage, transportAddress = self.socket.recvfrom(65535) + debug.logger & debug.flagIO and debug.logger('handle_read: transportAddress %s incomintMessage %s' % (transportAddress, repr(incomingMessage))) if not incomingMessage: self.handle_close() return |