Author: astitcher
Date: Tue Jun 23 20:02:13 2009
New Revision: 787809

URL: http://svn.apache.org/viewvc?rev=787809&view=rev
Log:
Make sure you close down heartbeatTimer for every close even if you don't
need to do anything else

Modified:
    qpid/trunk/qpid/cpp/src/qpid/client/ConnectionImpl.cpp

Modified: qpid/trunk/qpid/cpp/src/qpid/client/ConnectionImpl.cpp
URL: 
http://svn.apache.org/viewvc/qpid/trunk/qpid/cpp/src/qpid/client/ConnectionImpl.cpp?rev=787809&r1=787808&r2=787809&view=diff
==============================================================================
--- qpid/trunk/qpid/cpp/src/qpid/client/ConnectionImpl.cpp (original)
+++ qpid/trunk/qpid/cpp/src/qpid/client/ConnectionImpl.cpp Tue Jun 23 20:02:13 
2009
@@ -176,10 +176,11 @@
 
 void ConnectionImpl::close()
 {
-    if (!handler.isOpen()) return;
     if (heartbeatTask) {
         heartbeatTask->cancel();
     }
+
+    if (!handler.isOpen()) return;
     handler.close();
     closed(CLOSE_CODE_NORMAL, "Closed by client");
 }



---------------------------------------------------------------------
Apache Qpid - AMQP Messaging Implementation
Project:      http://qpid.apache.org
Use/Interact: mailto:commits-subscr...@qpid.apache.org

Reply via email to