From d3747e09567909eed1917c65b19eeef24315e3dd Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?=E6=9C=80=E8=90=8C=E5=B0=8F=E6=B1=90?= Date: Tue, 24 Sep 2019 15:57:07 +0800 Subject: =?UTF-8?q?=E8=AF=BB=E5=8F=96=E5=8D=8F=E8=AE=AE=E6=98=AF=E5=B8=B8?= =?UTF-8?q?=E9=A9=BB=E4=BB=BB=E5=8A=A1?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- server-beta/src/proto/proto.lua | 11 +---------- 1 file changed, 1 insertion(+), 10 deletions(-) (limited to 'server-beta/src/proto') diff --git a/server-beta/src/proto/proto.lua b/server-beta/src/proto/proto.lua index cc9988a8..27ba68b8 100644 --- a/server-beta/src/proto/proto.lua +++ b/server-beta/src/proto/proto.lua @@ -112,16 +112,7 @@ function m.listen() subprocess.filemode(io.stdout, 'b') io.stdin:setvbuf 'no' io.stdout:setvbuf 'no' - task.create(function () - while true do - local proto = pub.task('loadProto') - if proto.method then - m.doMethod(proto) - else - m.doResponse(proto) - end - end - end) + pub.syncTask('loadProto') end return m -- cgit v1.2.3