Skip to content

Commit

Permalink
Fixes #905 - Fixes https with proxy when no port defined for server.
Browse files Browse the repository at this point in the history
  • Loading branch information
fviard committed Aug 12, 2017
1 parent 21f36f5 commit 11d56a9
Showing 1 changed file with 3 additions and 2 deletions.
5 changes: 3 additions & 2 deletions S3/ConnMan.py
Original file line number Diff line number Diff line change
Expand Up @@ -209,8 +209,9 @@ def __init__(self, id, hostname, ssl, cfg):
if ssl:
self.c = http_connection._https_connection(cfg.proxy_host, cfg.proxy_port)
debug(u'proxied HTTPSConnection(%s, %s)', cfg.proxy_host, cfg.proxy_port)
self.c.set_tunnel(self.hostname, self.port)
debug(u'tunnel to %s, %s', self.hostname, self.port)
port = self.port and self.port or 443
self.c.set_tunnel(self.hostname, port)
debug(u'tunnel to %s, %s', self.hostname, port)
else:
self.c = httplib.HTTPConnection(cfg.proxy_host, cfg.proxy_port)
debug(u'proxied HTTPConnection(%s, %s)', cfg.proxy_host, cfg.proxy_port)
Expand Down

0 comments on commit 11d56a9

Please sign in to comment.