diff options
Diffstat (limited to 'net/server_epoll.lua')
-rw-r--r-- | net/server_epoll.lua | 3 |
1 files changed, 2 insertions, 1 deletions
diff --git a/net/server_epoll.lua b/net/server_epoll.lua index fcc7e99d..117fa1dc 100644 --- a/net/server_epoll.lua +++ b/net/server_epoll.lua @@ -21,6 +21,7 @@ local socket = require "socket"; local luasec = require "ssl"; local gettime = require "util.time".now; local createtable = require "util.table".create; +local _SOCKETINVALID = socket._SOCKETINVALID or -1; assert(socket.tcp6 and socket.tcp4, "Incompatible LuaSocket version"); @@ -157,7 +158,7 @@ function interface:getfd() if self.conn then return self.conn:getfd(); end - return -1; + return _SOCKETINVALID; end -- Get IP address |