Skip to content
This repository has been archived by the owner on Jul 28, 2021. It is now read-only.

Commit

Permalink
Idle connections fix
Browse files Browse the repository at this point in the history
  • Loading branch information
nickname76 committed Aug 31, 2020
1 parent 8901390 commit ac3a740
Showing 1 changed file with 2 additions and 0 deletions.
2 changes: 2 additions & 0 deletions protdial.go
Original file line number Diff line number Diff line change
Expand Up @@ -223,13 +223,15 @@ func pipeBothIOsAndClose(parentctx context.Context, a io.ReadWriteCloser, b io.R
wg.Done()
if err != nil {
onErrFn(fmt.Errorf("pipeBothIOsAndClose b<-a: %s", err))
cancel()
}
}()
go func() {
_, err := io.Copy(a, b)
wg.Done()
if err != nil {
onErrFn(fmt.Errorf("pipeBothIOsAndClose a<-b: %s", err))
cancel()
}
}()

Expand Down

0 comments on commit ac3a740

Please sign in to comment.