mirror of
https://github.com/ShadowNinja/LuaIRC.git
synced 2025-06-27 05:40:30 +02:00
Sleep between thoughts when connecting to avoid eating CPU
This commit is contained in:
parent
b1cbbf1963
commit
2ccee2a935
1
init.lua
1
init.lua
@ -137,6 +137,7 @@ function meta_preconnect:connect(_host, _port)
|
|||||||
|
|
||||||
repeat
|
repeat
|
||||||
self:think()
|
self:think()
|
||||||
|
socket.select(nil, nil, 0.1) -- Sleep so that we don't eat CPU
|
||||||
until self.authed
|
until self.authed
|
||||||
end
|
end
|
||||||
|
|
||||||
|
Loading…
x
Reference in New Issue
Block a user