aboutsummaryrefslogtreecommitdiffstats
path: root/net/server_epoll.lua
diff options
context:
space:
mode:
authorKim Alvefur <zash@zash.se>2018-10-12 03:21:11 +0200
committerKim Alvefur <zash@zash.se>2018-10-12 03:21:11 +0200
commit906bc714b636f475caf7960922ba75c75a0395e7 (patch)
treeb66b4c6be21c25064428da381dc42381fbee012c /net/server_epoll.lua
parent56c2772487be14a1dde2d2da7929725d8035f5fb (diff)
downloadprosody-906bc714b636f475caf7960922ba75c75a0395e7.tar.gz
prosody-906bc714b636f475caf7960922ba75c75a0395e7.zip
net.server_epoll: Ignore ENOENT when deregitering socket
It should not really happen
Diffstat (limited to 'net/server_epoll.lua')
-rw-r--r--net/server_epoll.lua3
1 files changed, 2 insertions, 1 deletions
diff --git a/net/server_epoll.lua b/net/server_epoll.lua
index fc939675..cb83c8c3 100644
--- a/net/server_epoll.lua
+++ b/net/server_epoll.lua
@@ -27,6 +27,7 @@ local _SOCKETINVALID = socket._SOCKETINVALID or -1;
local poller = require "util.poll"
local EEXIST = poller.EEXIST;
+local ENOENT = poller.ENOENT;
local poll = assert(poller.new());
@@ -310,7 +311,7 @@ function interface:del()
return nil, "unregistered fd";
end
local ok, err, errno = poll:del(fd);
- if not ok then
+ if not ok and errno ~= ENOENT then
log("error", "Could not unregister %s: %s(%d)", self, err, errno);
return ok, err;
end