From 508ee5e549cd81e65dc770b3b9dd25c7fc147239 Mon Sep 17 00:00:00 2001 From: Tobias Klauser Date: Wed, 19 Jan 2022 15:22:52 +0100 Subject: [PATCH] Don't set poller.fd twice in newFdPoller (#406) In newEmptyPoller when creating the poller using newEmptyPoller(fd), the fd field of the poller instance is already set. There is no need to set it again. --- inotify_poller.go | 1 - 1 file changed, 1 deletion(-) diff --git a/inotify_poller.go b/inotify_poller.go index e9ff943..b572a37 100644 --- a/inotify_poller.go +++ b/inotify_poller.go @@ -38,7 +38,6 @@ func newFdPoller(fd int) (*fdPoller, error) { poller.close() } }() - poller.fd = fd // Create epoll fd poller.epfd, errno = unix.EpollCreate1(unix.EPOLL_CLOEXEC) -- 2.50.1