Skip to content

Commit 87b34c9

Browse files
committed
timer_wrap: add sanity check assert
1 parent 9193062 commit 87b34c9

1 file changed

Lines changed: 3 additions & 0 deletions

File tree

src/timer_wrap.cc

Lines changed: 3 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -67,7 +67,10 @@ class TimerWrap : public HandleWrap {
6767
TimerWrap(Handle<Object> object)
6868
: HandleWrap(object, (uv_handle_t*) &handle_) {
6969
active_ = false;
70+
7071
int r = uv_timer_init(uv_default_loop(), &handle_);
72+
assert(r == 0);
73+
7174
handle_.data = this;
7275

7376
// uv_timer_init adds a loop reference. (That is, it calls uv_ref.) This

0 commit comments

Comments
 (0)