diff --git a/simple-tcp-proxy.go b/simple-tcp-proxy.go index 032ec3b..66bcfc9 100644 --- a/simple-tcp-proxy.go +++ b/simple-tcp-proxy.go @@ -47,7 +47,7 @@ func main() { return } if len(tcpListenConfig.TcpListens) == 0 { - fmt.Println("[ERROR] Not find any mapping in config") + fmt.Printf("[ERROR] Not find any mapping in config\n") printHelpMessage() return } @@ -62,7 +62,7 @@ func main() { func serverTcpListen(tcpListen TcpListen) { lis, err := net.Listen("tcp", tcpListen.Listen) if err != nil { - fmt.Println(err) + fmt.Printf("[ERROR] Listen on port %s error: %s\n", tcpListen.Listen, err) return } defer lis.Close()