Skip to content

Instantly share code, notes, and snippets.

@bnoordhuis
Created June 18, 2013 21:24
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 bnoordhuis/45ecd219f80b91f266e8 to your computer and use it in GitHub Desktop.
Save bnoordhuis/45ecd219f80b91f266e8 to your computer and use it in GitHub Desktop.
diff --git a/src/unix/timer.c b/src/unix/timer.c
index 57d32f5..c4f3816 100644
--- a/src/unix/timer.c
+++ b/src/unix/timer.c
@@ -62,7 +62,7 @@ int uv_timer_start(uv_timer_t* handle,
if (uv__is_active(handle))
uv_timer_stop(handle);
- clamped_timeout = handle->loop->time + timeout;
+ clamped_timeout = handle->loop->time + timeout + 1;
if (clamped_timeout < timeout)
clamped_timeout = (uint64_t) -1;
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment