move skynet.memlimit from skynet.manager to skynet

This commit is contained in:
Cloud Wu
2016-05-07 09:23:01 +08:00
parent 4b96ade660
commit a5c79cc4bd
4 changed files with 7 additions and 5 deletions

View File

@@ -656,6 +656,11 @@ function skynet.term(service)
return _error_dispatch(0, service)
end
function skynet.memlimit(bytes)
debug.getregistry().memlimit = bytes
skynet.memlimit = nil -- set only once
end
local function clear_pool()
coroutine_pool = {}
end