diff options
| author | Rafael H. Schloming <rhs@apache.org> | 2009-12-26 12:42:57 +0000 |
|---|---|---|
| committer | Rafael H. Schloming <rhs@apache.org> | 2009-12-26 12:42:57 +0000 |
| commit | 248f1fe188fe2307b9dcf2c87a83b653eaa1920c (patch) | |
| tree | d5d0959a70218946ff72e107a6c106e32479a398 /cpp/src/qpid/framing/SequenceSet.cpp | |
| parent | 3c83a0e3ec7cf4dc23e83a340b25f5fc1676f937 (diff) | |
| download | qpid-python-248f1fe188fe2307b9dcf2c87a83b653eaa1920c.tar.gz | |
synchronized with trunk except for ruby dir
git-svn-id: https://svn.apache.org/repos/asf/qpid/branches/qpid.rnr@893970 13f79535-47bb-0310-9956-ffa450edef68
Diffstat (limited to 'cpp/src/qpid/framing/SequenceSet.cpp')
| -rw-r--r-- | cpp/src/qpid/framing/SequenceSet.cpp | 7 |
1 files changed, 4 insertions, 3 deletions
diff --git a/cpp/src/qpid/framing/SequenceSet.cpp b/cpp/src/qpid/framing/SequenceSet.cpp index 9610b9180c..dcfb4689b6 100644 --- a/cpp/src/qpid/framing/SequenceSet.cpp +++ b/cpp/src/qpid/framing/SequenceSet.cpp @@ -19,8 +19,8 @@ * */ -#include "SequenceSet.h" -#include "Buffer.h" +#include "qpid/framing/SequenceSet.h" +#include "qpid/framing/Buffer.h" #include "qpid/framing/reply_exceptions.h" using namespace qpid::framing; @@ -46,6 +46,7 @@ void SequenceSet::encode(Buffer& buffer) const void SequenceSet::decode(Buffer& buffer) { + clear(); uint16_t size = buffer.getShort(); uint16_t count = size / RANGE_SIZE;//number of ranges if (size % RANGE_SIZE) @@ -56,7 +57,7 @@ void SequenceSet::decode(Buffer& buffer) } } -uint32_t SequenceSet::size() const { +uint32_t SequenceSet::encodedSize() const { return 2 /*size field*/ + (rangesSize() * RANGE_SIZE); } |
