From 36da2e1aabdd130123e43060a3e606361299690f Mon Sep 17 00:00:00 2001 From: Kim Alvefur Date: Sat, 3 Feb 2018 17:36:55 +0100 Subject: server_epoll: Restore mark on connections which had the onconnect handler called so it is only done once --- net/server_epoll.lua | 5 ++++- 1 file changed, 4 insertions(+), 1 deletion(-) (limited to 'net') diff --git a/net/server_epoll.lua b/net/server_epoll.lua index 7aad9ede..6da05f0e 100644 --- a/net/server_epoll.lua +++ b/net/server_epoll.lua @@ -539,7 +539,10 @@ end -- Connected! function interface:onconnect() self:setflags(true, false); - self:on("connect"); + if not self._connected then + self._connected = true; + self:on("connect"); + end end function interface:onfirstwritable() -- cgit v1.2.3