Navigation Menu

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

Commit

Permalink
unix: fix assertion failure when the signal pipe overflows
Browse files Browse the repository at this point in the history
An incorrect assert() statement was causing libuv to crash when writing
to an internal signal pipe would result in EAGAIN/EWOULDBLOCK.

This commit doesn't solve the underlying issue that the signal pipe can
overflow.

This should fix nodejs/node-v0.x-archive#5538
  • Loading branch information
piscisaureus committed May 23, 2013
1 parent c53fe81 commit 9df9b5d
Showing 1 changed file with 1 addition and 1 deletion.
2 changes: 1 addition & 1 deletion src/unix/signal.c
Expand Up @@ -160,7 +160,7 @@ static void uv__signal_handler(int signum) {
} while (r == -1 && errno == EINTR);

assert(r == sizeof msg ||
(r == -1 && errno != EAGAIN && errno != EWOULDBLOCK));
(r == -1 && (errno == EAGAIN || errno == EWOULDBLOCK)));

if (r != -1)
handle->caught_signals++;
Expand Down

0 comments on commit 9df9b5d

Please sign in to comment.