From 2f6d6ad7efd788b71204af67dff51b6233881e2e Mon Sep 17 00:00:00 2001 From: Alan Conway Date: Fri, 21 Sep 2007 18:26:37 +0000 Subject: Split broker::Session into: broker::SessionState: session info (uuid etc.) + handler chains. broker::SemanticState: session state for the SemanticHandler. git-svn-id: https://svn.apache.org/repos/asf/incubator/qpid/trunk/qpid@578219 13f79535-47bb-0310-9956-ffa450edef68 --- cpp/src/qpid/broker/Connection.cpp | 7 +++---- 1 file changed, 3 insertions(+), 4 deletions(-) (limited to 'cpp/src/qpid/broker/Connection.cpp') diff --git a/cpp/src/qpid/broker/Connection.cpp b/cpp/src/qpid/broker/Connection.cpp index ec6fd6ece7..b1b8abe4fd 100644 --- a/cpp/src/qpid/broker/Connection.cpp +++ b/cpp/src/qpid/broker/Connection.cpp @@ -23,7 +23,7 @@ #include #include "Connection.h" -#include "Session.h" +#include "SessionState.h" #include "qpid/framing/AMQP_ClientProxy.h" #include "BrokerAdapter.h" #include "SemanticHandler.h" @@ -52,8 +52,7 @@ void Connection::received(framing::AMQFrame& frame){ if (frame.getChannel() == 0) { adapter.handle(frame); } else { - SessionHandler sa = getChannel(frame.getChannel()); - sa.in(frame); + getChannel(frame.getChannel()).in(frame); } } @@ -94,7 +93,7 @@ void Connection::closeChannel(uint16_t id) { if (i != channels.end()) channels.erase(i); } -SessionHandler Connection::getChannel(ChannelId id) { +SessionHandler& Connection::getChannel(ChannelId id) { boost::optional& ch = channels[id]; if (!ch) { ch = boost::in_place(boost::ref(*this), id); -- cgit v1.2.1