diff options
| author | Alain Vongsouvanh <alainv@google.com> | 2011-11-09 12:11:40 -0800 |
|---|---|---|
| committer | Alain Vongsouvanh <alainv@google.com> | 2011-11-09 12:11:40 -0800 |
| commit | df24e4b801ab6e3b4618e18ed43b4fbe6c8f66bf (patch) | |
| tree | d91b58162892d562cd85b8322197134f4e1ef04f /python2 | |
| parent | 5cf7c9c0f74df3b856f6bdd573e8e02660c18262 (diff) | |
| download | httplib2-df24e4b801ab6e3b4618e18ed43b4fbe6c8f66bf.tar.gz | |
Raise an exception in AppEngineHttpConnection.getresponse if response is None.
Diffstat (limited to 'python2')
| -rw-r--r-- | python2/httplib2/__init__.py | 5 |
1 files changed, 4 insertions, 1 deletions
diff --git a/python2/httplib2/__init__.py b/python2/httplib2/__init__.py index 334177e..fbd2d76 100644 --- a/python2/httplib2/__init__.py +++ b/python2/httplib2/__init__.py @@ -994,6 +994,10 @@ try: def getresponse(self): return self.response + if self.response: + return self.response + else: + raise httplib.HTTPException() def set_debuglevel(self, level): pass @@ -1160,7 +1164,6 @@ and more. conn.close() conn.connect() continue - pass try: response = conn.getresponse() except (socket.error, httplib.HTTPException): |
