Commit a58fe3bd authored by Dave Cheney's avatar Dave Cheney Committed by Brad Fitzpatrick

websocket: fix socket leak in test

Possibly fixes issue 1694.

R=bradfitzgo
CC=golang-dev
https://golang.org/cl/4427049
parent 99b0eefd
......@@ -186,11 +186,12 @@ func TestTrailingSpaces(t *testing.T) {
once.Do(startServer)
for i := 0; i < 30; i++ {
// body
_, err := Dial(fmt.Sprintf("ws://%s/echo", serverAddr), "",
"http://localhost/")
ws, err := Dial(fmt.Sprintf("ws://%s/echo", serverAddr), "", "http://localhost/")
if err != nil {
panic("Dial failed: " + err.String())
t.Error("Dial failed:", err.String())
break
}
ws.Close()
}
}
......
Markdown is supported
0%
or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment