diff options
author | Gordon Sim <gsim@apache.org> | 2007-09-06 20:27:33 +0000 |
---|---|---|
committer | Gordon Sim <gsim@apache.org> | 2007-09-06 20:27:33 +0000 |
commit | b33a63b36c659a894143382d0a61efe6a598fcc6 (patch) | |
tree | 0efc848ae9cc6064d615c6968b1d127e92b231d3 /cpp/src/qpid/client/ConnectionImpl.cpp | |
parent | 748698e4b8d5bd0c3ccec4ca898d334c13fc0795 (diff) | |
download | qpid-python-b33a63b36c659a894143382d0a61efe6a598fcc6.tar.gz |
Implementation of execution.result on the client side
git-svn-id: https://svn.apache.org/repos/asf/incubator/qpid/trunk/qpid@573359 13f79535-47bb-0310-9956-ffa450edef68
Diffstat (limited to 'cpp/src/qpid/client/ConnectionImpl.cpp')
-rw-r--r-- | cpp/src/qpid/client/ConnectionImpl.cpp | 9 |
1 files changed, 5 insertions, 4 deletions
diff --git a/cpp/src/qpid/client/ConnectionImpl.cpp b/cpp/src/qpid/client/ConnectionImpl.cpp index b4d2156c31..5ff34cde4e 100644 --- a/cpp/src/qpid/client/ConnectionImpl.cpp +++ b/cpp/src/qpid/client/ConnectionImpl.cpp @@ -60,11 +60,11 @@ void ConnectionImpl::handle(framing::AMQFrame& frame) void ConnectionImpl::incoming(framing::AMQFrame& frame) { uint16_t id = frame.getChannel(); - SessionCore::shared_ptr session = sessions[id]; - if (!session) { + SessionMap::iterator i = sessions.find(id); + if (i == sessions.end()) { throw ConnectionException(504, (boost::format("Invalid channel number %g") % id).str()); } - session->handle(frame); + i->second->handle(frame); } void ConnectionImpl::open(const std::string& host, int port, @@ -111,7 +111,8 @@ void ConnectionImpl::idleOut() connector->send(frame); } -void ConnectionImpl::shutdown() { +void ConnectionImpl::shutdown() +{ //this indicates that the socket to the server has closed for (SessionMap::iterator i = sessions.begin(); i != sessions.end(); i++) { i->second->closed(0, "Unexpected socket closure."); |