Skip to content

Instantly share code, notes, and snippets.

@rphillips
Created August 7, 2012 20:46
Show Gist options
  • Star 0 You must be signed in to star a gist
  • Fork 0 You must be signed in to fork a gist
  • Save rphillips/fa040d89afc801cd7d97 to your computer and use it in GitHub Desktop.
Save rphillips/fa040d89afc801cd7d97 to your computer and use it in GitHub Desktop.
diff --git a/lib/luvit/uv.lua b/lib/luvit/uv.lua
index 74fbc3c..240a317 100644
--- a/lib/luvit/uv.lua
+++ b/lib/luvit/uv.lua
@@ -256,6 +256,9 @@ function Timer:start(timeout, interval, callback)
end
function Timer:close()
+ if self._closed then
+ return
+ end
if not self._closed then
Handle.close(self)
end
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment