_, error := connection.Read(buffer)
buffer := make([]byte, BUFFER_SIZE)
splited := strings.Split(string(buffer), " ")
switch splited[0] {
case "TEST":
connection.Write([]byte("TEST CONNECTION OK"))
log.Printf("TEST COMMAND")
break;
If I write "TEST" in client, the server will not enter the case statement. But if I send "TEST SOMETHING" from client, the server will enter it as expected. Is this a bug of go-lang?