Skip to content

Commit

Permalink
buffer the error channel in the notify pipe logic to avoid blocking
Browse files Browse the repository at this point in the history
Signed-off-by: David Vossel <[email protected]>
  • Loading branch information
davidvossel committed Jul 16, 2020
1 parent 67f6b3c commit 90996f5
Showing 1 changed file with 1 addition and 1 deletion.
2 changes: 1 addition & 1 deletion pkg/virt-handler/vm.go
Original file line number Diff line number Diff line change
Expand Up @@ -233,7 +233,7 @@ func handleDomainNotifyPipe(domainPipeStopChan chan struct{}, ln net.Listener, v
defer conn.Close()

log.Log.Object(vmi).Infof("Accepted new notify pipe connection for vmi")
copyErr := make(chan error)
copyErr := make(chan error, 2)
go func() {
_, err := io.Copy(fd, conn)
copyErr <- err
Expand Down

0 comments on commit 90996f5

Please sign in to comment.