From e8f6b7cd234088e7c33e42eb10e29719ea8e8aa9 Mon Sep 17 00:00:00 2001 From: Alan Conway Date: Wed, 3 Sep 2008 03:21:00 +0000 Subject: Cluster multicasts buffers rather than frames. git-svn-id: https://svn.apache.org/repos/asf/incubator/qpid/trunk/qpid@691489 13f79535-47bb-0310-9956-ffa450edef68 --- cpp/src/qpid/framing/AMQFrame.cpp | 7 +++++++ 1 file changed, 7 insertions(+) (limited to 'cpp/src/qpid/framing/AMQFrame.cpp') diff --git a/cpp/src/qpid/framing/AMQFrame.cpp b/cpp/src/qpid/framing/AMQFrame.cpp index c1fc647b52..662b3574ff 100644 --- a/cpp/src/qpid/framing/AMQFrame.cpp +++ b/cpp/src/qpid/framing/AMQFrame.cpp @@ -45,6 +45,13 @@ uint32_t AMQFrame::frameOverhead() { return 12 /*frame header*/; } +uint16_t AMQFrame::DECODE_SIZE_MIN=4; + +uint16_t AMQFrame::decodeSize(char* data) { + Buffer buf(data+2, DECODE_SIZE_MIN); + return buf.getShort(); +} + void AMQFrame::encode(Buffer& buffer) const { //set track first (controls on track 0, everything else on 1): -- cgit v1.2.1