Skip to content

Commit

Permalink
Browse files Browse the repository at this point in the history
bugfix: check for closing handle
  • Loading branch information
Ryan Phillips committed Sep 5, 2012
1 parent 950c457 commit 0cf8e07
Showing 1 changed file with 3 additions and 0 deletions.
3 changes: 3 additions & 0 deletions src/luv_handle.c
Expand Up @@ -84,6 +84,9 @@ void luv_on_close(uv_handle_t* handle) {
int luv_close (lua_State* L) {
uv_handle_t* handle = luv_checkudata(L, 1, "handle");
/* printf("close \tlhandle=%p handle=%p\n", handle->data, handle);*/
if (uv_is_closing(handle)) {
return;
}
uv_close(handle, luv_on_close);
luv_handle_ref(L, handle->data, 1);
return 0;
Expand Down

0 comments on commit 0cf8e07

Please sign in to comment.