From 5da289cd5bf0f3c367d3eb091ac66e5f4ce2b97c Mon Sep 17 00:00:00 2001 From: Ian Barber Date: Sat, 9 Jun 2012 00:07:30 +0100 Subject: [PATCH] Code formatting, and clean up so that xhiccuped is only handled in case the pipe isn't terminating --- src/socket_base.cpp | 9 ++++----- 1 file changed, 4 insertions(+), 5 deletions(-) diff --git a/src/socket_base.cpp b/src/socket_base.cpp index 7e1aa0c6..4614675a 100644 --- a/src/socket_base.cpp +++ b/src/socket_base.cpp @@ -970,12 +970,11 @@ void zmq::socket_base_t::write_activated (pipe_t *pipe_) void zmq::socket_base_t::hiccuped (pipe_t *pipe_) { - if( options.delay_attach_on_connect == 1 ) { + if (options.delay_attach_on_connect == 1) pipe_->terminate (false); - } - - // Notify derived sockets of the hiccup - xhiccuped (pipe_); + else + // Notify derived sockets of the hiccup + xhiccuped (pipe_); } void zmq::socket_base_t::terminated (pipe_t *pipe_)