From 993c09ec70614b78cc16c86ec4c8d17dbafef1a1 Mon Sep 17 00:00:00 2001 From: Yann Leboulanger Date: Wed, 21 Dec 2005 17:55:57 +0000 Subject: [PATCH] catch correct exception when interrupt system call --- src/common/helpers.py | 2 +- src/common/xmpp/transports.py | 2 +- 2 files changed, 2 insertions(+), 2 deletions(-) diff --git a/src/common/helpers.py b/src/common/helpers.py index 9186f92f4..eac8be05a 100644 --- a/src/common/helpers.py +++ b/src/common/helpers.py @@ -138,7 +138,7 @@ def temp_failure_retry(func, *args, **kwargs): while True: try: return func(*args, **kwargs) - except (os.error, IOError, socket.error), ex: + except (os.error, IOError, select.error), ex: if ex.errno == errno.EINTR: continue else: diff --git a/src/common/xmpp/transports.py b/src/common/xmpp/transports.py index 7358e1e92..3c4e13ac7 100644 --- a/src/common/xmpp/transports.py +++ b/src/common/xmpp/transports.py @@ -42,7 +42,7 @@ def temp_failure_retry(func, *args, **kwargs): while True: try: return func(*args, **kwargs) - except (os.error, IOError, socket.error), ex: + except (os.error, IOError, select.error), ex: if ex.errno == errno.EINTR: continue else: