aboutsummaryrefslogtreecommitdiffstats
path: root/libpathod/pathod.py
diff options
context:
space:
mode:
Diffstat (limited to 'libpathod/pathod.py')
-rw-r--r--libpathod/pathod.py10
1 files changed, 5 insertions, 5 deletions
diff --git a/libpathod/pathod.py b/libpathod/pathod.py
index 93f7a8ae..e71701fb 100644
--- a/libpathod/pathod.py
+++ b/libpathod/pathod.py
@@ -21,7 +21,7 @@ class PathodHandler(tcp.BaseHandler):
wbufsize = 0
sni = None
def info(self, s):
- logger.info("%s:%s: %s"%(self.client_address[0], self.client_address[1], str(s)))
+ logger.info("%s:%s: %s"%(self.address.host, self.address.port, str(s)))
def handle_sni(self, connection):
self.sni = connection.get_servername()
@@ -118,7 +118,7 @@ class PathodHandler(tcp.BaseHandler):
headers = headers.lst,
httpversion = httpversion,
sni = self.sni,
- remote_address = self.client_address,
+ remote_address = self.address(),
clientcert = clientcert
)
@@ -155,13 +155,13 @@ class PathodHandler(tcp.BaseHandler):
return False, dict(type = "error", msg="Access denied: web interface disabled")
else:
self.info("app: %s %s"%(method, path))
- cc = wsgi.ClientConn(self.client_address)
+ cc = wsgi.ClientConn(self.address())
req = wsgi.Request(cc, "http", method, path, headers, content)
sn = self.connection.getsockname()
a = wsgi.WSGIAdaptor(
self.server.app,
sn[0],
- self.server.port,
+ self.server.address.port,
version.NAMEVERSION
)
a.serve(req, self.wfile)
@@ -282,7 +282,7 @@ class Pathod(tcp.TCPServer):
staticdir = self.staticdir
)
- def handle_connection(self, request, client_address):
+ def handle_client_connection(self, request, client_address):
h = PathodHandler(request, client_address, self)
try:
h.handle()