X-Git-Url: https://pintos-os.org/cgi-bin/gitweb.cgi?a=blobdiff_plain;f=lib%2Fnetlink-socket.c;h=0f4e3e77d848aa66cb8af1121bd640b925f9973f;hb=7593daa2473c464cd179420b9c7f68989044fdee;hp=3674bacbf48905d55454dab16757b85289bb7755;hpb=50802adb0e00bbf381c31b9e32a7a6a3e920e7ac;p=openvswitch diff --git a/lib/netlink-socket.c b/lib/netlink-socket.c index 3674bacb..0f4e3e77 100644 --- a/lib/netlink-socket.c +++ b/lib/netlink-socket.c @@ -668,6 +668,14 @@ nl_sock_wait(const struct nl_sock *sock, short int events) poll_fd_wait(sock->fd, events); } +/* Checks whether this socket caused a wakeup in the previous run of the poll + * loop. */ +short int +nl_sock_woke(const struct nl_sock *sock) +{ + return poll_fd_woke(sock->fd); +} + /* Returns the PID associated with this socket. */ uint32_t nl_sock_pid(const struct nl_sock *sock)