net.server_event, net.server_select: Fixed some global pollution.
--- a/net/server_event.lua Fri Aug 12 00:01:35 2011 +0200
+++ b/net/server_event.lua Fri Oct 14 00:46:29 2011 +0500
@@ -827,14 +827,14 @@
end
end
-function get_backend()
+local function get_backend()
return base:method();
end
-- We need to hold onto the events to stop them
-- being garbage-collected
local signal_events = {}; -- [signal_num] -> event object
-function hook_signal(signal_num, handler)
+local function hook_signal(signal_num, handler)
local function _handler(event)
local ret = handler();
if ret ~= false then -- Continue handling this signal?
--- a/net/server_select.lua Fri Aug 12 00:01:35 2011 +0200
+++ b/net/server_select.lua Fri Oct 14 00:46:29 2011 +0500
@@ -781,7 +781,7 @@
local quitting;
-setquitting = function (quit)
+local function setquitting(quit)
quitting = not not quit;
end
@@ -832,7 +832,7 @@
return "quitting"
end
-step = function ()
+local function step()
return loop(true);
end