mirror of
https://github.com/cloudwu/skynet.git
synced 2026-07-24 12:20:41 +00:00
fix a bug , issue #592
This commit is contained in:
@@ -269,7 +269,7 @@ function COMMANDX.debug(cmd)
|
|||||||
local function forward_cmd()
|
local function forward_cmd()
|
||||||
repeat
|
repeat
|
||||||
-- notice : It's a bad practice to call socket.readline from two threads (this one and console_main_loop), be careful.
|
-- notice : It's a bad practice to call socket.readline from two threads (this one and console_main_loop), be careful.
|
||||||
skynet.call(agent, "lua", "cmd", "ping") -- detect agent alive, if agent exit, raise error
|
skynet.call(agent, "lua", "ping") -- detect agent alive, if agent exit, raise error
|
||||||
local cmdline = socket.readline(cmd.fd, "\n")
|
local cmdline = socket.readline(cmd.fd, "\n")
|
||||||
cmdline = cmdline and cmdline:gsub("(.*)\r$", "%1")
|
cmdline = cmdline and cmdline:gsub("(.*)\r$", "%1")
|
||||||
if not cmdline then
|
if not cmdline then
|
||||||
|
|||||||
Reference in New Issue
Block a user