diff options
author | Jason A. Donenfeld <Jason@zx2c4.com> | 2021-09-27 14:18:38 -0600 |
---|---|---|
committer | Jason A. Donenfeld <Jason@zx2c4.com> | 2021-09-27 14:19:15 -0600 |
commit | bb745b2ea3264bb764cac77c4fa8e69cf9b2a975 (patch) | |
tree | 9ead346dee4c446f99dc79f954aef40c2ec3682b /rwcancel/rwcancel.go | |
parent | fcc601dbf0f6b626ec1d47a880cbe64f9c8fe385 (diff) | |
download | wireguard-go-bb745b2ea3264bb764cac77c4fa8e69cf9b2a975.tar.gz wireguard-go-bb745b2ea3264bb764cac77c4fa8e69cf9b2a975.zip |
rwcancel: use unix.Poll again but bump x/sys so it uses ppoll under the hood
This reverts commit fcc601dbf0f6b626ec1d47a880cbe64f9c8fe385 but then
bumps go.mod.
Signed-off-by: Jason A. Donenfeld <Jason@zx2c4.com>
Diffstat (limited to 'rwcancel/rwcancel.go')
-rw-r--r-- | rwcancel/rwcancel.go | 4 |
1 files changed, 2 insertions, 2 deletions
diff --git a/rwcancel/rwcancel.go b/rwcancel/rwcancel.go index 45cc73b..7013b16 100644 --- a/rwcancel/rwcancel.go +++ b/rwcancel/rwcancel.go @@ -49,7 +49,7 @@ func (rw *RWCancel) ReadyRead() bool { pollFds := []unix.PollFd{{Fd: int32(rw.fd), Events: unix.POLLIN}, {Fd: closeFd, Events: unix.POLLIN}} var err error for { - _, err = poll(pollFds, -1) + _, err = unix.Poll(pollFds, -1) if err == nil || !RetryAfterError(err) { break } @@ -68,7 +68,7 @@ func (rw *RWCancel) ReadyWrite() bool { pollFds := []unix.PollFd{{Fd: int32(rw.fd), Events: unix.POLLOUT}, {Fd: closeFd, Events: unix.POLLOUT}} var err error for { - _, err = poll(pollFds, -1) + _, err = unix.Poll(pollFds, -1) if err == nil || !RetryAfterError(err) { break } |