use a patch to hotfix

This commit is contained in:
Cloud Wu
2014-04-17 13:49:25 +08:00
parent 58dfe38c4b
commit 6d4d9f8758
4 changed files with 88 additions and 91 deletions

View File

@@ -6,7 +6,23 @@ skynet.start(function()
print(ps.pub.hello())
print(ps.req.ping("foobar"))
print(pcall(ps.req.error))
snax.hotfix(ps)
print("Hotfix (i) :", snax.hotfix(ps, [[
local i
local hello
function subscribe.hello()
i = i + 1
print ("fix", i, hello)
end
function hotfix(...)
local temp = i
i = 100
return temp
end
]]))
print(ps.pub.hello())
print(snax.kill(ps,"exit"))
skynet.exit()