Skip to content

Commit

Permalink
mailbox::recv correctly passes EINTR to the caller
Browse files Browse the repository at this point in the history
This bug caused signal during blocking call to assert.

Signed-off-by: Martin Sustrik <sustrik@250bpm.com>
  • Loading branch information
sustrik committed Jul 21, 2011
1 parent 4bd3359 commit 75c4e0e
Showing 1 changed file with 1 addition and 1 deletion.
2 changes: 1 addition & 1 deletion src/mailbox.cpp
Expand Up @@ -66,7 +66,7 @@ int zmq::mailbox_t::recv (command_t *cmd_, int timeout_)

// Wait for signal from the command sender.
int rc = signaler.wait (timeout_);
if (rc != 0 && errno == EAGAIN)
if (rc != 0 && (errno == EAGAIN || errno == EINTR))
return -1;

// We've got the signal. Now we can switch into active state.
Expand Down

0 comments on commit 75c4e0e

Please sign in to comment.