diff options
| author | Ted Ross <tross@apache.org> | 2009-06-11 15:54:37 +0000 |
|---|---|---|
| committer | Ted Ross <tross@apache.org> | 2009-06-11 15:54:37 +0000 |
| commit | 52be8c6219f98781d83711b32d4c5971b1fa6d1c (patch) | |
| tree | 812f608b9472a76d757e92be8dc3a184a2e2ae13 /cpp/src/qpid/management | |
| parent | 2a61047873520b644cbc368ebd59fb2d5a0c217d (diff) | |
| download | qpid-python-52be8c6219f98781d83711b32d4c5971b1fa6d1c.tar.gz | |
QPID-1786 - Committed qmf patches from Bryan Kearney
Additionally updated existing qmf and Qman to be compatible.
The magic number for qmf messages has been incremented.
git-svn-id: https://svn.apache.org/repos/asf/qpid/trunk/qpid@783818 13f79535-47bb-0310-9956-ffa450edef68
Diffstat (limited to 'cpp/src/qpid/management')
| -rw-r--r-- | cpp/src/qpid/management/ManagementAgent.cpp | 19 |
1 files changed, 17 insertions, 2 deletions
diff --git a/cpp/src/qpid/management/ManagementAgent.cpp b/cpp/src/qpid/management/ManagementAgent.cpp index 8fcc5264e4..d0ad80902b 100644 --- a/cpp/src/qpid/management/ManagementAgent.cpp +++ b/cpp/src/qpid/management/ManagementAgent.cpp @@ -246,7 +246,7 @@ void ManagementAgent::encodeHeader (Buffer& buf, uint8_t opcode, uint32_t seq) { buf.putOctet ('A'); buf.putOctet ('M'); - buf.putOctet ('2'); + buf.putOctet ('3'); buf.putOctet (opcode); buf.putLong (seq); } @@ -260,7 +260,7 @@ bool ManagementAgent::checkHeader (Buffer& buf, uint8_t *opcode, uint32_t *seq) *opcode = buf.getOctet(); *seq = buf.getLong(); - return h1 == 'A' && h2 == 'M' && h3 == '2'; + return h1 == 'A' && h2 == 'M' && h3 == '3'; } void ManagementAgent::sendBuffer(Buffer& buf, @@ -1097,10 +1097,18 @@ size_t ManagementAgent::validateTableSchema(Buffer& inBuffer) inBuffer.getShortString(text); inBuffer.getBin128(hash); + uint8_t superType = inBuffer.getOctet(); + uint16_t propCount = inBuffer.getShort(); uint16_t statCount = inBuffer.getShort(); uint16_t methCount = inBuffer.getShort(); + if (superType == 1) { + inBuffer.getShortString(text); + inBuffer.getShortString(text); + inBuffer.getBin128(hash); + } + for (uint16_t idx = 0; idx < propCount + statCount; idx++) { FieldTable ft; ft.decode(inBuffer); @@ -1142,9 +1150,16 @@ size_t ManagementAgent::validateEventSchema(Buffer& inBuffer) inBuffer.getShortString(text); inBuffer.getShortString(text); inBuffer.getBin128(hash); + + uint8_t superType = inBuffer.getOctet(); uint16_t argCount = inBuffer.getShort(); + if (superType == 1) { + inBuffer.getShortString(text); + inBuffer.getShortString(text); + inBuffer.getBin128(hash); + } for (uint16_t idx = 0; idx < argCount; idx++) { FieldTable ft; ft.decode(inBuffer); |
