summaryrefslogtreecommitdiffstats
path: root/Lib/urllib/request.py
diff options
context:
space:
mode:
authorSerhiy Storchaka <storchaka@gmail.com>2014-07-22 08:02:56 (GMT)
committerSerhiy Storchaka <storchaka@gmail.com>2014-07-22 08:02:56 (GMT)
commitcb7d43cbdff11a49f841883f8daf7135bc2cdac8 (patch)
treec8cde7ba16edc1847ed807de2f620106b4013da9 /Lib/urllib/request.py
parent17f5f817de1b9ad8cdff783838f9d44a6a920ae5 (diff)
parentbc07ac51801ae261ce09f057cbb4ecf9b7cdc07c (diff)
downloadcpython-cb7d43cbdff11a49f841883f8daf7135bc2cdac8.zip
cpython-cb7d43cbdff11a49f841883f8daf7135bc2cdac8.tar.gz
cpython-cb7d43cbdff11a49f841883f8daf7135bc2cdac8.tar.bz2
Merge heads
Diffstat (limited to 'Lib/urllib/request.py')
-rw-r--r--Lib/urllib/request.py2
1 files changed, 1 insertions, 1 deletions
diff --git a/Lib/urllib/request.py b/Lib/urllib/request.py
index 72e91dd..0389f5e 100644
--- a/Lib/urllib/request.py
+++ b/Lib/urllib/request.py
@@ -1315,7 +1315,7 @@ class FileHandler(BaseHandler):
url = req.selector
if url[:2] == '//' and url[2:3] != '/' and (req.host and
req.host != 'localhost'):
- if not req.host is self.get_names():
+ if not req.host in self.get_names():
raise URLError("file:// scheme is supported only on localhost")
else:
return self.open_local_file(req)