From 2ccee2a9350e2abab2bcf0066ecadee1947e0267 Mon Sep 17 00:00:00 2001 From: ShadowNinja Date: Sat, 22 Feb 2014 17:44:03 -0500 Subject: [PATCH] Sleep between thoughts when connecting to avoid eating CPU --- init.lua | 1 + 1 file changed, 1 insertion(+) diff --git a/init.lua b/init.lua index d3c3369..99ae7f5 100644 --- a/init.lua +++ b/init.lua @@ -137,6 +137,7 @@ function meta_preconnect:connect(_host, _port) repeat self:think() + socket.select(nil, nil, 0.1) -- Sleep so that we don't eat CPU until self.authed end