remove task overload warning

This commit is contained in:
Cloud Wu
2015-05-13 09:50:53 +08:00
parent 82fa2f979c
commit 9e27f59033

View File

@@ -97,7 +97,6 @@ end
local coroutine_pool = {}
local coroutine_yield = coroutine.yield
local coroutine_count = 0
local function co_create(f)
local co = table.remove(coroutine_pool)
@@ -111,11 +110,6 @@ local function co_create(f)
f(coroutine_yield())
end
end)
coroutine_count = coroutine_count + 1
if coroutine_count > 1024 then
skynet.error("May overload, create 1024 task")
coroutine_count = 0
end
else
coroutine.resume(co, f)
end