From 09242894a37dd8720bca865533c8ccda2c20ceb7 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?=E4=BA=91=E9=A3=8E?= Date: Wed, 30 Oct 2013 16:48:04 +0800 Subject: [PATCH] fix typo: coroutine_pool --- lualib/skynet.lua | 8 ++++---- 1 file changed, 4 insertions(+), 4 deletions(-) diff --git a/lualib/skynet.lua b/lualib/skynet.lua index 8a26ac1a..f3fb4fac 100644 --- a/lualib/skynet.lua +++ b/lualib/skynet.lua @@ -30,17 +30,17 @@ local trace_func = function() end -- coroutine reuse -local coroutine_poll = {} +local coroutine_pool = {} local coroutine_yield = coroutine.yield local function co_create(f) - local co = table.remove(coroutine_poll) + local co = table.remove(coroutine_pool) if co == nil then co = coroutine.create(function(...) f(...) while true do f = nil - coroutine_poll[#coroutine_poll] = co + coroutine_pool[#coroutine_pool] = co f = coroutine_yield "EXIT" f(coroutine_yield()) end @@ -481,7 +481,7 @@ function dbgcmd.MEM() end function dbgcmd.GC() - coroutine_poll = {} + coroutine_pool = {} collectgarbage "collect" end