Software /
code /
prosody
Changeset
7737:f93b3083b46b
net.server_epoll: Use _SOCKETINVALID from LuaSocket
author | Kim Alvefur <zash@zash.se> |
---|---|
date | Wed, 23 Nov 2016 17:27:44 +0100 |
parents | 7735:1502ec4f3cbe |
children | 7745:6d6a04628954 |
files | net/server_epoll.lua |
diffstat | 1 files changed, 2 insertions(+), 1 deletions(-) [+] |
line wrap: on
line diff
--- a/net/server_epoll.lua Mon Nov 21 02:40:47 2016 +0100 +++ b/net/server_epoll.lua Wed Nov 23 17:27:44 2016 +0100 @@ -21,6 +21,7 @@ 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 @@ if self.conn then return self.conn:getfd(); end - return -1; + return _SOCKETINVALID; end -- Get IP address