diff options
Diffstat (limited to 'qpid/cpp/lib/broker/BrokerMessage.cpp')
-rw-r--r-- | qpid/cpp/lib/broker/BrokerMessage.cpp | 1 |
1 files changed, 1 insertions, 0 deletions
diff --git a/qpid/cpp/lib/broker/BrokerMessage.cpp b/qpid/cpp/lib/broker/BrokerMessage.cpp index 7fa1444a9e..50bf319797 100644 --- a/qpid/cpp/lib/broker/BrokerMessage.cpp +++ b/qpid/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) { |