diff options
author | Raymond Hettinger <python@rcn.com> | 2004-10-14 15:23:38 (GMT) |
---|---|---|
committer | Raymond Hettinger <python@rcn.com> | 2004-10-14 15:23:38 (GMT) |
commit | 4d03791632a9b7a6d96640df09466969aec81b71 (patch) | |
tree | a2f1732973fb11b8e9905e7614ca4803b2c31adb | |
parent | 3079391b8ded86351b47617663a9ae54b6fc7c66 (diff) | |
download | cpython-4d03791632a9b7a6d96640df09466969aec81b71.zip cpython-4d03791632a9b7a6d96640df09466969aec81b71.tar.gz cpython-4d03791632a9b7a6d96640df09466969aec81b71.tar.bz2 |
SF bug #1046855: httplib index out of range
-rw-r--r-- | Lib/httplib.py | 2 |
1 files changed, 1 insertions, 1 deletions
diff --git a/Lib/httplib.py b/Lib/httplib.py index d4fcf7c..72e8a72 100644 --- a/Lib/httplib.py +++ b/Lib/httplib.py @@ -593,7 +593,7 @@ class HTTPConnection: host = host[:i] else: port = self.default_port - if host[0] == '[' and host[-1] == ']': + if host and host[0] == '[' and host[-1] == ']': host = host[1:-1] self.host = host self.port = port |