Use buffered channel to receive read error.

This commit is contained in:
Joachim Bauch 2021-04-29 14:49:59 +02:00
parent c91b0de254
commit 0d1c546355
No known key found for this signature in database
GPG Key ID: 77C1D22D53E15F02
1 changed files with 1 additions and 1 deletions

View File

@ -191,7 +191,7 @@ func NewTestClient(t *testing.T, server *httptest.Server, hub *Hub) *TestClient
}
messageChan := make(chan []byte)
readErrorChan := make(chan error)
readErrorChan := make(chan error, 1)
go func() {
for {