diff options
Diffstat (limited to 'swiftclient/client.py')
-rw-r--r-- | swiftclient/client.py | 9 |
1 files changed, 7 insertions, 2 deletions
diff --git a/swiftclient/client.py b/swiftclient/client.py index b9f12aa..0635090 100644 --- a/swiftclient/client.py +++ b/swiftclient/client.py @@ -1798,8 +1798,13 @@ class Connection: service_token=self.service_token, **kwargs) self._add_response_dict(caller_response_dict, kwargs) return rv - except SSLError: - raise + except SSLError as e: + self._add_response_dict(caller_response_dict, kwargs) + if ('certificate verify' in str(e)) or \ + ('hostname' in str(e)) or \ + self.attempts > self.retries: + raise + self.http_conn = None except (socket.error, RequestException): self._add_response_dict(caller_response_dict, kwargs) if self.attempts > self.retries: |