From b519c53fe4986ad999097340789f8bc0c1d8dcfe Mon Sep 17 00:00:00 2001 From: Cloud Wu Date: Mon, 22 Jul 2024 00:52:19 +0800 Subject: [PATCH] Try to fix #1958 --- service/clusteragent.lua | 3 ++- 1 file changed, 2 insertions(+), 1 deletion(-) diff --git a/service/clusteragent.lua b/service/clusteragent.lua index 742e8083..09b444b0 100644 --- a/service/clusteragent.lua +++ b/service/clusteragent.lua @@ -131,7 +131,8 @@ skynet.start(function() dispatch = dispatch_request, } -- fd can write, but don't read fd, the data package will forward from gate though client protocol. - skynet.call(gate, "lua", "forward", fd) + -- forward may fail, see https://github.com/cloudwu/skynet/issues/1958 + pcall(skynet.call,gate, "lua", "forward", fd) skynet.dispatch("lua", function(_,source, cmd, ...) if cmd == "exit" then