diff options
author | Brian Geffon <bgeffon@google.com> | 2018-06-13 16:20:30 -0700 |
---|---|---|
committer | Shentubot <shentubot@google.com> | 2018-06-13 16:21:23 -0700 |
commit | 1170039e788db368615451a0a1f5cfccb1d28d41 (patch) | |
tree | 356d00827f6c08ea8d53ad1023f1ebd829f445c8 /pkg/sentry/socket/rpcinet | |
parent | 7b7b199ed0e282c42a753b1dc2ee16fe15aaa6d3 (diff) |
Fix missing returns in rpcinet.
PiperOrigin-RevId: 200472634
Change-Id: I3f0fb9e3b2f8616e6aa1569188258f330bf1ed31
Diffstat (limited to 'pkg/sentry/socket/rpcinet')
-rw-r--r-- | pkg/sentry/socket/rpcinet/socket.go | 6 |
1 files changed, 3 insertions, 3 deletions
diff --git a/pkg/sentry/socket/rpcinet/socket.go b/pkg/sentry/socket/rpcinet/socket.go index 4ef8b91c3..d8c1f2c1a 100644 --- a/pkg/sentry/socket/rpcinet/socket.go +++ b/pkg/sentry/socket/rpcinet/socket.go @@ -288,7 +288,7 @@ func (s *socketOperations) Bind(t *kernel.Task, sockaddr []byte) *syserr.Error { <-c if e := stack.rpcConn.Request(id).Result.(*pb.SyscallResponse_Bind).Bind.ErrorNumber; e != 0 { - syserr.FromHost(syscall.Errno(e)) + return syserr.FromHost(syscall.Errno(e)) } return nil } @@ -300,7 +300,7 @@ func (s *socketOperations) Listen(t *kernel.Task, backlog int) *syserr.Error { <-c if e := stack.rpcConn.Request(id).Result.(*pb.SyscallResponse_Listen).Listen.ErrorNumber; e != 0 { - syserr.FromHost(syscall.Errno(e)) + return syserr.FromHost(syscall.Errno(e)) } return nil } @@ -361,7 +361,7 @@ func (s *socketOperations) SetSockOpt(t *kernel.Task, level int, name int, opt [ <-c if e := stack.rpcConn.Request(id).Result.(*pb.SyscallResponse_SetSockOpt).SetSockOpt.ErrorNumber; e != 0 { - syserr.FromHost(syscall.Errno(e)) + return syserr.FromHost(syscall.Errno(e)) } return nil } |