Commits

Jason R. Coombs committed b68e275

Fixed issue where proxy bypass detection failed when a port was specified.

  • Participants
  • Parent commits a966c67
  • Branches issue 159

Comments (0)

Files changed (1)

File python2/httplib2/__init__.py

 import zlib
 import httplib
 import urlparse
+import urllib
 import base64
 import os
 import copy
         """Return a ProxyInfo instance (or None) based on the scheme
         and authority.
         """
+        hostname, port = urllib.splitport(authority)
         proxy_info = self.proxy_info
         if callable(proxy_info):
             proxy_info = proxy_info(scheme)
 
         if (hasattr(proxy_info, 'applies_to')
-            and not proxy_info.applies_to(authority)):
+            and not proxy_info.applies_to(hostname)):
             proxy_info = None
         return proxy_info