The header symbols are declared extern "C",
however the the implementations are compiled in a C++ source.
The result is that the library symbols get C++ name mangled
and the resulting dll is missing all of the symbols from the header.
The fix was to add extern "C" in zmq.cpp and zmq_utils.cpp
backport of zeromq/libzmq#721
In the discussion, it was decided to backport, but that never actually happened.
test file was renamed after the above PR, so the version from master is pulled in here.
indentation was correct, but poll was inside `if control`,
causing it to only be called if there is a control message.
This would cause proxy messages to only be delivered after a control message had been sent.
This is a silly assertion that causes problems if libzmq.dll is
called in some esoteric ways.
Solution: if the shutdown code detects WSANOTINITIALISED, then
exit silently.
Fixes#1377Fixes#1144
Conflicts:
src/signaler.cpp
When Curve authentication is used, libsodium opens a file
descriptor to /dev/urandom to generate random bytes. When
the ZMQ context terminates, it should ensure that file gets
closed.
Updated:
src/signaler.cpp: Add close_wait_ms() static function to loop
when receiving EAGAIN in response to close(), with ms long
sleeps, up to a maximum limit (default 2000ms == 2 seconds);
used in signaler_t::~signaler_t() destructor.
The list of error codes is taken from zmq::wsa_error_no(). Most of the
new WSA error codes result in EFAULT, but some return a more specific
value (even EAGAIN).
Backport of zeromq/libzmq#1072
This bug is caused by fq which can terminate pipe before sending all
frames of a message first. So sometimes two messages were mixed and this
confused ZAP handler.
This patch just modifies one pipe parameter so that socket consumes all
messages before dropping the pipe.
This reverts commit f27eb67e1abb0484c41050e454404cce30647b63, reversing
changes made to a3ae0d4c16c892a4e6c96d626a7c8b7068450336.
Conflicts:
src/stream_engine.cpp
Conflicts were around additional defaults to the constructor after the
'terminating' default. The additional defaults were left alone, and
the 'terminating' default was removed.