ui: display * instead of 0.0.0.0 for the bound address

This commit is contained in:
Maximilian Hils 2014-09-03 12:24:14 +02:00
parent 1e4e332ef9
commit 712e5860aa
3 changed files with 6 additions and 3 deletions

View File

@ -201,7 +201,10 @@ class StatusBar(common.WWrap):
]
if self.master.server.bound:
boundaddr = "[%s:%s]"%(self.master.server.address.host or "*", self.master.server.address.port)
host = self.master.server.address.host
if host == "0.0.0.0":
host = "*"
boundaddr = "[%s:%s]"%(host, self.master.server.address.port)
else:
boundaddr = ""
t.extend(self.get_status())

View File

@ -1068,7 +1068,7 @@ class HTTPHandler(ProtocolHandler):
message += " The client does not trust the proxy's certificate."
if isinstance(error, tcp.NetLibDisconnect):
self.c.log("TCP connection closed unexpectedly.", "debug", [repr(error)])
self.c.log("TCP connection closed unexpectedly.", "debug")
else:
self.c.log("error: %s" % message, level="info")

View File

@ -66,5 +66,5 @@ class TCPHandler(ProtocolHandler):
# self.c.log("%s %s\r\n%s" % (direction, dst_str, cleanBin(buf.tobytes())), "debug")
dst.connection.send(buf[:size])
except socket.error as e:
self.c.log("TCP connection closed unexpectedly.", "debug", [repr(e)])
self.c.log("TCP connection closed unexpectedly.", "debug")
return