Skip to content
This repository has been archived by the owner on May 4, 2018. It is now read-only.

Commit

Permalink
unix: uv_async handles should not be unref'ed automatically
Browse files Browse the repository at this point in the history
  • Loading branch information
piscisaureus committed Jun 9, 2012
1 parent 0ae026d commit fab7b7b
Show file tree
Hide file tree
Showing 2 changed files with 2 additions and 1 deletion.
1 change: 0 additions & 1 deletion src/unix/async.c
Expand Up @@ -40,7 +40,6 @@ int uv_async_init(uv_loop_t* loop, uv_async_t* async, uv_async_cb async_cb) {

/* Note: This does not have symmetry with the other libev wrappers. */
ev_async_start(loop->ev, &async->async_watcher);
uv__handle_unref(async);
uv__handle_start(async);

return 0;
Expand Down
2 changes: 2 additions & 0 deletions src/unix/uv-eio.c
Expand Up @@ -95,11 +95,13 @@ void uv_eio_init(uv_loop_t* loop) {
&loop->uv_eio_want_poll_notifier,
uv_eio_want_poll_notifier_cb);
loop->uv_eio_want_poll_notifier.flags |= UV__HANDLE_INTERNAL;
uv__handle_unref(&loop->uv_eio_want_poll_notifier);

uv_async_init(loop,
&loop->uv_eio_done_poll_notifier,
uv_eio_done_poll_notifier_cb);
loop->uv_eio_done_poll_notifier.flags |= UV__HANDLE_INTERNAL;
uv__handle_unref(&loop->uv_eio_done_poll_notifier);

uv_once(&uv__eio_init_once_guard, uv__eio_init);
}

0 comments on commit fab7b7b

Please sign in to comment.