We read every piece of feedback, and take your input very seriously.
To see all available qualifiers, see our documentation.
1 parent c62c0dc commit ff876f6Copy full SHA for ff876f6
1 file changed
conn_notjs.go
@@ -245,9 +245,11 @@ func (m *mu) lock(ctx context.Context) error {
245
case m.ch <- struct{}{}:
246
// To make sure the connection is certainly alive.
247
// As it's possible the send on m.ch was selected
248
- // the receive on closed.
+ // over the receive on closed.
249
select {
250
case <-m.c.closed:
251
+ // Make sure to release.
252
+ m.unlock()
253
return m.c.closeErr
254
default:
255
}
0 commit comments