zeromq/libzmq — pull request #334 by ianbarber (2012-05-03 12:25:02+00:00)
Title: Async connect error handling

Patch from Mato that fixes a subtle connect bug:

EAGAIN was being used as a translation value for EINPROGRESS, thus
shadowing a real EAGAIN return value from the OS. This caused later
assertions of "Invalid argument" in stream_engine.cpp when it attempted to
use a socket which was not connected.

I also add EINTR to mean EINPROGRESS, as per the POSIX and FreeBSD
documentation which specifies that a connect() call interrupted due to a
signal will complete asynchronously.

Signed-off-by: Martin Lucina