Skip to content

Commit

Permalink
Merge pull request #3 from gpu-ninja/main
Browse files Browse the repository at this point in the history
fix: Close the errors channel when a client disconnect occurs
  • Loading branch information
pojntfx authored Aug 8, 2023
2 parents c074303 + 2dbf323 commit 72b3d30
Showing 1 changed file with 4 additions and 0 deletions.
4 changes: 4 additions & 0 deletions pkg/client/nbd.go
Original file line number Diff line number Diff line change
Expand Up @@ -315,6 +315,10 @@ n:
}

go func() {
defer func() {
close(fatal)
}()

if _, _, err := syscall.Syscall(
syscall.SYS_IOCTL,
device.Fd(),
Expand Down

0 comments on commit 72b3d30

Please sign in to comment.