diff options
author | Gordon Sim <gsim@apache.org> | 2006-12-01 13:14:15 +0000 |
---|---|---|
committer | Gordon Sim <gsim@apache.org> | 2006-12-01 13:14:15 +0000 |
commit | 06f28d4054b259b95be0cb2862fcd78010e5a905 (patch) | |
tree | 564a4d64f9696a09beae7b869feae795fa1b1274 /cpp/lib/broker/BrokerMessage.cpp | |
parent | ba8f16d68f724048356a189a1b8bc96390499106 (diff) | |
download | qpid-python-06f28d4054b259b95be0cb2862fcd78010e5a905.tar.gz |
Fix to test. Throw exception where previously printed warning.
git-svn-id: https://svn.apache.org/repos/asf/incubator/qpid/trunk/qpid@481235 13f79535-47bb-0310-9956-ffa450edef68
Diffstat (limited to 'cpp/lib/broker/BrokerMessage.cpp')
-rw-r--r-- | cpp/lib/broker/BrokerMessage.cpp | 1 |
1 files changed, 1 insertions, 0 deletions
diff --git a/cpp/lib/broker/BrokerMessage.cpp b/cpp/lib/broker/BrokerMessage.cpp index 7fa1444a9e..50bf319797 100644 --- a/cpp/lib/broker/BrokerMessage.cpp +++ b/cpp/lib/broker/BrokerMessage.cpp @@ -140,6 +140,7 @@ void Message::decodeContent(Buffer& buffer, u_int32_t chunkSize) u_int64_t expected = expectedContentSize(); if (expected != buffer.available()) { std::cout << "WARN: Expected " << expectedContentSize() << " bytes, got " << buffer.available() << std::endl; + throw Exception("Cannot decode content, buffer not large enough."); } if (!chunkSize || chunkSize > expected) { |