diff options
| author | Gordon Sim <gsim@apache.org> | 2008-03-03 14:49:06 +0000 |
|---|---|---|
| committer | Gordon Sim <gsim@apache.org> | 2008-03-03 14:49:06 +0000 |
| commit | b4dac41573e33e1a04a2b7b8c9a35f5e72b662bc (patch) | |
| tree | 15e25a2dc7b42f3788f9dccdd7e632dcf8c346d2 /cpp/src/qpid/broker/ConnectionHandler.cpp | |
| parent | 928699508993a5ccc59254027773281883d1e973 (diff) | |
| download | qpid-python-b4dac41573e33e1a04a2b7b8c9a35f5e72b662bc.tar.gz | |
A further step to final 0-10 spec.
The extra.xml fragment adds class defs for connection in session that are in line with latest spec but use old schema.
The preview codepath (99-0) remains unaltered.
git-svn-id: https://svn.apache.org/repos/asf/incubator/qpid/trunk/qpid@633108 13f79535-47bb-0310-9956-ffa450edef68
Diffstat (limited to 'cpp/src/qpid/broker/ConnectionHandler.cpp')
| -rw-r--r-- | cpp/src/qpid/broker/ConnectionHandler.cpp | 10 |
1 files changed, 7 insertions, 3 deletions
diff --git a/cpp/src/qpid/broker/ConnectionHandler.cpp b/cpp/src/qpid/broker/ConnectionHandler.cpp index e296d52214..126e1b2723 100644 --- a/cpp/src/qpid/broker/ConnectionHandler.cpp +++ b/cpp/src/qpid/broker/ConnectionHandler.cpp @@ -23,6 +23,7 @@ #include "ConnectionHandler.h" #include "Connection.h" #include "qpid/framing/ConnectionStartBody.h" +#include "qpid/framing/Connection010StartBody.h" #include "qpid/framing/ClientInvoker.h" #include "qpid/framing/ServerInvoker.h" @@ -38,11 +39,14 @@ const std::string en_US = "en_US"; } void ConnectionHandler::init(const framing::ProtocolInitiation& header) { + //need to send out a protocol header back to the client + handler->connection.getOutput().initiated(header); + FieldTable properties; string mechanisms(PLAIN); string locales(en_US); - handler->serverMode = true; - handler->client.start(header.getMajor(), header.getMinor(), properties, mechanisms, locales); + handler->serverMode = true; + handler->client.start(properties, mechanisms, locales); } void ConnectionHandler::close(ReplyCode code, const string& text, ClassId classId, MethodId methodId) @@ -55,7 +59,7 @@ void ConnectionHandler::handle(framing::AMQFrame& frame) AMQMethodBody* method=frame.getBody()->getMethod(); try{ if (handler->serverMode) { - if (!invoke(static_cast<AMQP_ServerOperations::ConnectionHandler&>(*handler.get()), *method)) + if (!invoke(static_cast<AMQP_ServerOperations::Connection010Handler&>(*handler.get()), *method)) throw ChannelErrorException(QPID_MSG("Class can't be accessed over channel 0")); } else { if (!invoke(static_cast<AMQP_ClientOperations::ConnectionHandler&>(*handler.get()), *method)) |
