From 87cb0d5dc9cb7b6296044d4367e3c34dc48459ab Mon Sep 17 00:00:00 2001 From: v2ray Date: Fri, 17 Jun 2016 18:03:31 +0200 Subject: [PATCH] update log --- transport/internet/tcp_hub.go | 5 +++-- 1 file changed, 3 insertions(+), 2 deletions(-) diff --git a/transport/internet/tcp_hub.go b/transport/internet/tcp_hub.go index bd7e8afc9..7433c5488 100644 --- a/transport/internet/tcp_hub.go +++ b/transport/internet/tcp_hub.go @@ -42,10 +42,12 @@ func ListenTCP(address v2net.Address, port v2net.Port, callback ConnectionHandle case settings.IsCapableOf(StreamConnectionTypeRawTCP): listener, err = RawTCPListenFunc(address, port) default: + log.Error("Internet|Listener: Unknown stream type: ", settings.Type) err = ErrUnsupportedStreamType } if err != nil { + log.Warning("Internet|Listener: Failed to listen on ", address, ":", port) return nil, err } @@ -70,11 +72,10 @@ func (this *TCPHub) start() { if err != nil { if this.accepting { - log.Warning("Listener: Failed to accept new TCP connection: ", err) + log.Warning("Internet|Listener: Failed to accept new TCP connection: ", err) } continue } - log.Info("Handling connection from ", conn.RemoteAddr()) go this.connCallback(conn) } }