Skip to content

Commit

Permalink
Update socket.lua (#1197)
Browse files Browse the repository at this point in the history
如果监听套接字在accept时异常(例如:errno == EMFILE),那么不应该关闭监听套接字本身,输出异常信息即可。
  • Loading branch information
Fanrncho authored Jun 3, 2020
1 parent 1f22216 commit 9f86498
Showing 1 changed file with 4 additions and 0 deletions.
4 changes: 4 additions & 0 deletions lualib/skynet/socket.lua
Original file line number Diff line number Diff line change
Expand Up @@ -112,6 +112,10 @@ socket_message[5] = function(id, _, err)
skynet.error("socket: error on unknown", id, err)
return
end
if s.callback then
skynet.error("socket: accpet error:", err)
return
end
if s.connected then
skynet.error("socket: error on", id, err)
elseif s.connecting then
Expand Down

0 comments on commit 9f86498

Please sign in to comment.