diff options
| author | Kristján Valur Jónsson <kristjan@ccpgames.com> | 2009-07-03 23:26:02 +0000 |
|---|---|---|
| committer | Kristján Valur Jónsson <kristjan@ccpgames.com> | 2009-07-03 23:26:02 +0000 |
| commit | f83648ef48ebe93f43e041a808e705adffbf30b2 (patch) | |
| tree | 1c70859bf147dfe98931776bec8cd1ee8766f594 /Lib/xmlrpclib.py | |
| parent | b5faac73a44f8c0e86b37e448abcf6bb3c9de523 (diff) | |
| download | cpython-git-f83648ef48ebe93f43e041a808e705adffbf30b2.tar.gz | |
http://bugs.python.org/issue6267
Incorrect exception handling for xmlrp client retry
Diffstat (limited to 'Lib/xmlrpclib.py')
| -rw-r--r-- | Lib/xmlrpclib.py | 10 |
1 files changed, 5 insertions, 5 deletions
diff --git a/Lib/xmlrpclib.py b/Lib/xmlrpclib.py index 160b61c8e0..da3fb5a91c 100644 --- a/Lib/xmlrpclib.py +++ b/Lib/xmlrpclib.py @@ -1253,11 +1253,11 @@ class Transport: for i in (0, 1): try: return self.single_request(host, handler, request_body, verbose) - except (socket.error, httplib.HTTPException), e: - retry = (errno.ECONNRESET, - errno.ECONNABORTED, - httplib.BadStatusLine) #close after we sent request - if i or e[0] not in retry: + except socket.error, e: + if i or e.errno not in (errno.ECONNRESET, errno.ECONNABORTED): + raise + except http.client.BadStatusLine: #close after we sent request + if i: raise ## |
