projects
/
platform
/
upstream
/
nodejs.git
/ commitdiff
commit
grep
author
committer
pickaxe
?
search:
re
summary
|
shortlog
|
log
|
commit
| commitdiff |
tree
raw
|
patch
| inline |
side by side
(parent:
9193062
)
timer_wrap: add sanity check assert
author
Ben Noordhuis
<info@bnoordhuis.nl>
Fri, 14 Oct 2011 15:00:37 +0000
(15:00 +0000)
committer
Ben Noordhuis
<info@bnoordhuis.nl>
Fri, 14 Oct 2011 15:01:26 +0000
(15:01 +0000)
src/timer_wrap.cc
patch
|
blob
|
history
diff --git
a/src/timer_wrap.cc
b/src/timer_wrap.cc
index
cfae78d
..
99db0c5
100644
(file)
--- a/
src/timer_wrap.cc
+++ b/
src/timer_wrap.cc
@@
-67,7
+67,10
@@
class TimerWrap : public HandleWrap {
TimerWrap(Handle<Object> object)
: HandleWrap(object, (uv_handle_t*) &handle_) {
active_ = false;
+
int r = uv_timer_init(uv_default_loop(), &handle_);
+ assert(r == 0);
+
handle_.data = this;
// uv_timer_init adds a loop reference. (That is, it calls uv_ref.) This