-
Notifications
You must be signed in to change notification settings - Fork 68
Open
Description
Easily reproducible:
eslConn.Close()
eslConn.Send("connect")
ev, err := eslConn.ReadEvent()
No errors are emitted to the ReadEvent in this case, since it just listens on channels with no timeout or check against the connection state, and the err is read off h.err by the call to Send, I believe.
I propose adding a simple ReadWithTimeout, ReadWithDeadline, or ReadWithContext function to alleviate the issue, allowing us to back out of that select. Else, the connection error state needs to be persistent when ReadEvent is used.
Reactions are currently unavailable
Metadata
Metadata
Assignees
Labels
No labels