From cfa1cb0482e2f851125608e6eada7f48a33603eb Mon Sep 17 00:00:00 2001 From: Gordon Sim Date: Mon, 22 Jan 2007 11:49:39 +0000 Subject: Fixed creation of error message for unknown channel. git-svn-id: https://svn.apache.org/repos/asf/incubator/qpid/trunk@498591 13f79535-47bb-0310-9956-ffa450edef68 --- qpid/cpp/lib/broker/SessionHandlerImpl.cpp | 5 ++++- 1 file changed, 4 insertions(+), 1 deletion(-) (limited to 'qpid/cpp/lib/broker/SessionHandlerImpl.cpp') diff --git a/qpid/cpp/lib/broker/SessionHandlerImpl.cpp b/qpid/cpp/lib/broker/SessionHandlerImpl.cpp index da49a94d68..26cdfebad2 100644 --- a/qpid/cpp/lib/broker/SessionHandlerImpl.cpp +++ b/qpid/cpp/lib/broker/SessionHandlerImpl.cpp @@ -19,6 +19,7 @@ * */ #include +#include #include #include #include @@ -64,7 +65,9 @@ SessionHandlerImpl::~SessionHandlerImpl(){ Channel* SessionHandlerImpl::getChannel(u_int16_t channel){ channel_iterator i = channels.find(channel); if(i == channels.end()){ - throw ConnectionException(504, "Unknown channel: " + channel); + std::stringstream out; + out << "Unknown channel: " << channel; + throw ConnectionException(504, out.str()); } return i->second; } -- cgit v1.2.1