diff options
author | gVisor bot <gvisor-bot@google.com> | 2020-09-23 05:34:36 +0000 |
---|---|---|
committer | gVisor bot <gvisor-bot@google.com> | 2020-09-23 05:34:36 +0000 |
commit | 8f530839ccfbea4d8bfe49891b44d408beed0126 (patch) | |
tree | a1c5b9f68dd6f9bb66e3a374fc7ae349118a29cd /pkg/sentry/kernel/pipe | |
parent | 43ee43819bf4f2e433065def7908aa57f493f5a7 (diff) | |
parent | b54dbdfdc6b6cbdb6f45cd2abd9efb1f2f821a20 (diff) |
Merge release-20200914.0-136-gb54dbdfdc (automated)
Diffstat (limited to 'pkg/sentry/kernel/pipe')
-rw-r--r-- | pkg/sentry/kernel/pipe/pipe.go | 3 |
1 files changed, 2 insertions, 1 deletions
diff --git a/pkg/sentry/kernel/pipe/pipe.go b/pkg/sentry/kernel/pipe/pipe.go index c410c96aa..67beb0ad6 100644 --- a/pkg/sentry/kernel/pipe/pipe.go +++ b/pkg/sentry/kernel/pipe/pipe.go @@ -17,6 +17,7 @@ package pipe import ( "fmt" + "io" "sync/atomic" "syscall" @@ -215,7 +216,7 @@ func (p *Pipe) readLocked(ctx context.Context, ops readOps) (int64, error) { if p.view.Size() == 0 { if !p.HasWriters() { // There are no writers, return EOF. - return 0, nil + return 0, io.EOF } return 0, syserror.ErrWouldBlock } |