dbg for debug

This commit is contained in:
云风
2012-09-14 12:04:14 +08:00
parent 374b65d199
commit 32dee2bbaa
6 changed files with 101 additions and 11 deletions

View File

@@ -15,10 +15,7 @@ local function split_package()
while true do
local cmd = readline "\n"
if cmd ~= "" then
local handle = skynet.launch("snlua", cmd)
if handle == nil then
print("Launch error:",cmd)
end
skynet.send(skynet.self(), "text", cmd)
end
end
end
@@ -39,5 +36,11 @@ skynet.register_protocol {
skynet.start(function()
skynet.dispatch("text", function (session, address, cmd)
local handle = skynet.newservice(cmd)
if handle == nil then
print("Launch error:",cmd)
end
end)
socket.stdin()
end)