Discard "i/o timeout" messages when client close connection
This commit is contained in:
+1
-1
@@ -103,7 +103,7 @@ func handleConnection(connClt net.Conn, conLdap *ldap.Conn) {
|
||||
readlen, err := connClt.Read(buf)
|
||||
if err != nil {
|
||||
// Dont notice if client closed connection
|
||||
if err.Error() != "EOF" {
|
||||
if err.Error() != "EOF" && !strings.HasSuffix(err.Error(), "i/o timeout") {
|
||||
logstream.Err(fmt.Sprintln("Error reading connection :", err.Error()))
|
||||
}
|
||||
return
|
||||
|
||||
Reference in New Issue
Block a user