From b4e007b03518f32f82bc6f5f509ffad68f0d43cb Mon Sep 17 00:00:00 2001 From: rxi Date: Sun, 13 Apr 2014 16:43:57 +0100 Subject: [PATCH] Changed server to accept all waiting requests that frame Previously the server would have only handled the most recent connection on a frame, it now handles all waiting connections. --- lovebird.lua | 5 +++-- 1 file changed, 3 insertions(+), 2 deletions(-) diff --git a/lovebird.lua b/lovebird.lua index 53640f8..ae58358 100644 --- a/lovebird.lua +++ b/lovebird.lua @@ -550,8 +550,9 @@ end function lovebird.update() if not lovebird.inited then lovebird.init() end - local client = lovebird.server:accept() - if client then + while 1 do + local client = lovebird.server:accept() + if not client then break end client:settimeout(2) local addr = client:getsockname() if lovebird.checkwhitelist(addr) then