From a9e03336b020d2e6a83338b111092e65aa812f95 Mon Sep 17 00:00:00 2001 From: Martin Lucina Date: Thu, 15 Dec 2011 13:23:40 +0100 Subject: A synchronous connect() failure in ipc_connecter can result in Assertion failed: s == retired_fd (ipc_connecter.cpp:174), as reported in LIBZMQ-294. This patch fixes the bug, and also an identical problem in tcp_connecter which has not hit people since TCP connect() usually completes via the asynchronous code path (poll, out_event). Signed-off-by: Martin Lucina --- src/tcp_connecter.cpp | 1 + 1 file changed, 1 insertion(+) (limited to 'src/tcp_connecter.cpp') diff --git a/src/tcp_connecter.cpp b/src/tcp_connecter.cpp index 75079da..042e82a 100644 --- a/src/tcp_connecter.cpp +++ b/src/tcp_connecter.cpp @@ -146,6 +146,7 @@ void zmq::tcp_connecter_t::start_connecting () } // Handle any other error condition by eventual reconnect. + close (); wait = true; add_reconnect_timer(); } -- cgit v1.2.3