summaryrefslogtreecommitdiffhomepage
path: root/pkg/sentry/socket/rpcinet/notifier
diff options
context:
space:
mode:
authorgVisor bot <gvisor-bot@google.com>2019-08-08 11:58:11 -0700
committergVisor bot <gvisor-bot@google.com>2019-08-08 11:58:14 -0700
commit2e45d1696e41d9042164b1b05d0dcd39dd15dfce (patch)
tree933d95094567568908d881111781a9928328c047 /pkg/sentry/socket/rpcinet/notifier
parent06102af65ad2d0e5a89c5e7dfe281afd5346ed4f (diff)
parent83fdb7739e2da5636147bac89d2508be507801dc (diff)
Merge pull request #653 from xiaobo55x:dev
PiperOrigin-RevId: 262402929
Diffstat (limited to 'pkg/sentry/socket/rpcinet/notifier')
-rw-r--r--pkg/sentry/socket/rpcinet/notifier/BUILD3
-rw-r--r--pkg/sentry/socket/rpcinet/notifier/notifier.go3
2 files changed, 4 insertions, 2 deletions
diff --git a/pkg/sentry/socket/rpcinet/notifier/BUILD b/pkg/sentry/socket/rpcinet/notifier/BUILD
index a536f2e44..a3585e10d 100644
--- a/pkg/sentry/socket/rpcinet/notifier/BUILD
+++ b/pkg/sentry/socket/rpcinet/notifier/BUILD
@@ -6,10 +6,11 @@ go_library(
name = "notifier",
srcs = ["notifier.go"],
importpath = "gvisor.dev/gvisor/pkg/sentry/socket/rpcinet/notifier",
- visibility = ["//pkg/sentry:internal"],
+ visibility = ["//:sandbox"],
deps = [
"//pkg/sentry/socket/rpcinet:syscall_rpc_go_proto",
"//pkg/sentry/socket/rpcinet/conn",
"//pkg/waiter",
+ "@org_golang_x_sys//unix:go_default_library",
],
)
diff --git a/pkg/sentry/socket/rpcinet/notifier/notifier.go b/pkg/sentry/socket/rpcinet/notifier/notifier.go
index aa157dd51..7efe4301f 100644
--- a/pkg/sentry/socket/rpcinet/notifier/notifier.go
+++ b/pkg/sentry/socket/rpcinet/notifier/notifier.go
@@ -20,6 +20,7 @@ import (
"sync"
"syscall"
+ "golang.org/x/sys/unix"
"gvisor.dev/gvisor/pkg/sentry/socket/rpcinet/conn"
pb "gvisor.dev/gvisor/pkg/sentry/socket/rpcinet/syscall_rpc_go_proto"
"gvisor.dev/gvisor/pkg/waiter"
@@ -76,7 +77,7 @@ func (n *Notifier) waitFD(fd uint32, fi *fdInfo, mask waiter.EventMask) error {
}
e := pb.EpollEvent{
- Events: mask.ToLinux() | -syscall.EPOLLET,
+ Events: mask.ToLinux() | unix.EPOLLET,
Fd: fd,
}