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

Commit

Permalink
uv-unix: set stream->accepted_fd=-1 in uv_pipe_init()
Browse files Browse the repository at this point in the history
stream->accepted_fd was zeroed in uv_pipe_init() and that made
uv__finish_close() close the stdin file descriptor. Not good.
  • Loading branch information
bnoordhuis committed Aug 1, 2011
1 parent e9bee51 commit a3852a7
Showing 1 changed file with 1 addition and 0 deletions.
1 change: 1 addition & 0 deletions src/uv-unix.c
Expand Up @@ -1838,6 +1838,7 @@ int uv_pipe_init(uv_pipe_t* handle) {
ev_init(&handle->read_watcher, uv__stream_io);
handle->write_watcher.data = handle;
handle->read_watcher.data = handle;
handle->accepted_fd = -1;
handle->fd = -1;

ngx_queue_init(&handle->write_completed_queue);
Expand Down

0 comments on commit a3852a7

Please sign in to comment.