From 750daccfc6fcbd66331732421d80027dd1086254 Mon Sep 17 00:00:00 2001 From: Josiah Carlson Date: Tue, 10 Jun 2008 15:58:19 +0000 Subject: Fixed test to reflect new filedispatcher semantics, as well as two NameErrors pointed out by Giampaolo. --- Lib/asyncore.py | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) (limited to 'Lib/asyncore.py') diff --git a/Lib/asyncore.py b/Lib/asyncore.py index 184c993d5e..305d8957de 100644 --- a/Lib/asyncore.py +++ b/Lib/asyncore.py @@ -228,7 +228,7 @@ class dispatcher: # passed be connected. try: self.addr = sock.getpeername() - except socket.error: + except socket.error, err: if err[0] == ENOTCONN: # To handle the case where we got an unconnected # socket. @@ -424,7 +424,7 @@ class dispatcher: #check for errors err = self.socket.getsockopt(socket.SOL_SOCKET, socket.SO_ERROR) if err != 0: - raise socket.error(err, strerror(err)) + raise socket.error(err, _strerror(err)) self.handle_connect_event() self.handle_write() -- cgit v1.2.1