From 2efb7bb5c2bbd3df778710cfb67a630fa6d4d0fa Mon Sep 17 00:00:00 2001 From: Gordon Sim Date: Tue, 1 Sep 2009 15:22:48 +0000 Subject: QPID-2078: Ensure sessions are cleaned up when their connection is closed by management. git-svn-id: https://svn.apache.org/repos/asf/qpid/trunk@810094 13f79535-47bb-0310-9956-ffa450edef68 --- qpid/cpp/src/qpid/broker/Connection.cpp | 6 ++++-- 1 file changed, 4 insertions(+), 2 deletions(-) (limited to 'qpid/cpp/src') diff --git a/qpid/cpp/src/qpid/broker/Connection.cpp b/qpid/cpp/src/qpid/broker/Connection.cpp index a1a3c6ada7..3b8a6c71d4 100644 --- a/qpid/cpp/src/qpid/broker/Connection.cpp +++ b/qpid/cpp/src/qpid/broker/Connection.cpp @@ -269,11 +269,13 @@ bool Connection::doOutput() { cb(); // Lend the IO thread for management processing } } - if (mgmtClosing) + if (mgmtClosing) { + closed(); close(connection::CLOSE_CODE_CONNECTION_FORCED, "Closed by Management Request"); - else + } else { //then do other output as needed: return outputTasks.doOutput(); + } }catch(ConnectionException& e){ close(e.code, e.getMessage()); }catch(std::exception& e){ -- cgit v1.2.1