mirror of
https://github.com/cloudwu/skynet.git
synced 2026-07-22 02:53:09 +00:00
return 0 when send to an invalid address
This commit is contained in:
@@ -302,7 +302,8 @@ _send(lua_State *L) {
|
||||
}
|
||||
if (session < 0) {
|
||||
// send to invalid address
|
||||
return 0;
|
||||
// todo: maybe throw error is better
|
||||
session = 0;
|
||||
}
|
||||
lua_pushinteger(L,session);
|
||||
return 1;
|
||||
|
||||
Reference in New Issue
Block a user