mirror of
https://github.com/zeromq/libzmq.git
synced 2025-11-07 05:58:45 +01:00
Revert "On the advice of Martin Hurton, removed the new command type and just terminated the pipe in a reconnect situation, and notified the socket of the same. This handles the blocking properly, but at the cost of potentially losing in flight messages. However, this is a reasonable trade off given how much simpler it makes the patch."
This reverts commit c13f1d52ff.
This commit is contained in:
@@ -876,6 +876,17 @@ void zmq::socket_base_t::process_destroy ()
|
||||
destroyed = true;
|
||||
}
|
||||
|
||||
void zmq::socket_base_t::process_detach (pipe_t *pipe_)
|
||||
{
|
||||
// If we are blocking connecting threads, drop this one
|
||||
if (options.delay_attach_on_connect == 1) {
|
||||
zmq_assert (pipe_);
|
||||
pipes.erase (pipe_);
|
||||
// Let derived sockets know we're ditching this pipe
|
||||
xterminated (pipe_);
|
||||
}
|
||||
}
|
||||
|
||||
int zmq::socket_base_t::xsetsockopt (int option_, const void *optval_,
|
||||
size_t optvallen_)
|
||||
{
|
||||
|
||||
Reference in New Issue
Block a user