summaryrefslogtreecommitdiff
path: root/cpp/src/qpid/client/ConnectionImpl.h
diff options
context:
space:
mode:
authorAlan Conway <aconway@apache.org>2008-05-23 13:39:07 +0000
committerAlan Conway <aconway@apache.org>2008-05-23 13:39:07 +0000
commit896d94f7c27e958806b96b537a7a96208ede145a (patch)
tree35c139fcc037fde8fef675d9d730882d22781931 /cpp/src/qpid/client/ConnectionImpl.h
parentbb4584d228b837fa70839560d72bc2a59dc1aa17 (diff)
downloadqpid-python-896d94f7c27e958806b96b537a7a96208ede145a.tar.gz
qpid::SessionState: Added error checking for invalid frame sequences.
client: Fix client crash on error during connection shutdown. git-svn-id: https://svn.apache.org/repos/asf/incubator/qpid/trunk/qpid@659538 13f79535-47bb-0310-9956-ffa450edef68
Diffstat (limited to 'cpp/src/qpid/client/ConnectionImpl.h')
-rw-r--r--cpp/src/qpid/client/ConnectionImpl.h8
1 files changed, 5 insertions, 3 deletions
diff --git a/cpp/src/qpid/client/ConnectionImpl.h b/cpp/src/qpid/client/ConnectionImpl.h
index 986b044b49..ac28a0f695 100644
--- a/cpp/src/qpid/client/ConnectionImpl.h
+++ b/cpp/src/qpid/client/ConnectionImpl.h
@@ -33,6 +33,7 @@
#include <map>
#include <boost/shared_ptr.hpp>
#include <boost/weak_ptr.hpp>
+#include <boost/enable_shared_from_this.hpp>
namespace qpid {
namespace client {
@@ -43,7 +44,8 @@ class SessionImpl;
class ConnectionImpl : public Bounds,
public framing::FrameHandler,
public sys::TimeoutHandler,
- public sys::ShutdownHandler
+ public sys::ShutdownHandler,
+ public boost::enable_shared_from_this<ConnectionImpl>
{
typedef std::map<uint16_t, boost::weak_ptr<SessionImpl> > SessionMap;
@@ -59,8 +61,6 @@ class ConnectionImpl : public Bounds,
template <class F> void detachAll(const F&);
- void open(const std::string& host, int port);
-
SessionVector closeInternal(const sys::Mutex::ScopedLock&);
void incoming(framing::AMQFrame& frame);
void closed(uint16_t, const std::string&);
@@ -73,6 +73,8 @@ class ConnectionImpl : public Bounds,
ConnectionImpl(framing::ProtocolVersion version, const ConnectionSettings& settings);
~ConnectionImpl();
+ void open(const std::string& host, int port);
+
void addSession(const boost::shared_ptr<SessionImpl>&);
void close();