From f344a49755ef16f02595e289c30cfdb0616f61c6 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?=E4=B8=81=E5=A4=A7=E9=BE=99?= <6268385+dingdalong@users.noreply.github.com> Date: Fri, 17 Feb 2023 14:36:32 +0800 Subject: [PATCH] =?UTF-8?q?=E4=BF=AE=E5=A4=8Dclient=5Fnumber=E8=AE=A1?= =?UTF-8?q?=E6=95=B0=E9=94=99=E8=AF=AF=20(#1704)?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- lualib/snax/gateserver.lua | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/lualib/snax/gateserver.lua b/lualib/snax/gateserver.lua index 75cd6e54..ee438637 100644 --- a/lualib/snax/gateserver.lua +++ b/lualib/snax/gateserver.lua @@ -90,6 +90,7 @@ function gateserver.start(handler) MSG.more = dispatch_queue function MSG.open(fd, msg) + client_number = client_number + 1 if client_number >= maxclient then socketdriver.shutdown(fd) return @@ -98,7 +99,6 @@ function gateserver.start(handler) socketdriver.nodelay(fd) end connection[fd] = true - client_number = client_number + 1 handler.connect(fd, msg) end