summaryrefslogtreecommitdiff
path: root/cpp/src
diff options
context:
space:
mode:
authorKenneth Anthony Giusti <kgiusti@apache.org>2011-11-02 16:44:02 +0000
committerKenneth Anthony Giusti <kgiusti@apache.org>2011-11-02 16:44:02 +0000
commit3e35392fcb2d496fa5da863adb42903416f44d44 (patch)
treef3757c766fe53309999df3d2ddf3619472c2ff8f /cpp/src
parentfd7342fe5531015187917e589653e5b2d80c85dd (diff)
downloadqpid-python-3e35392fcb2d496fa5da863adb42903416f44d44.tar.gz
QPID-3577: assign null group identifiers to the default group
git-svn-id: https://svn.apache.org/repos/asf/qpid/trunk/qpid@1196682 13f79535-47bb-0310-9956-ffa450edef68
Diffstat (limited to 'cpp/src')
-rw-r--r--cpp/src/qpid/broker/MessageGroupManager.cpp5
1 files changed, 4 insertions, 1 deletions
diff --git a/cpp/src/qpid/broker/MessageGroupManager.cpp b/cpp/src/qpid/broker/MessageGroupManager.cpp
index 77108c10d5..00d1a58bef 100644
--- a/cpp/src/qpid/broker/MessageGroupManager.cpp
+++ b/cpp/src/qpid/broker/MessageGroupManager.cpp
@@ -77,12 +77,15 @@ MessageGroupManager::GroupState& MessageGroupManager::findGroup( const QueuedMes
if (headers) {
qpid::framing::FieldTable::ValuePtr id = headers->get( groupIdHeader );
if (id && id->convertsTo<std::string>()) {
- group = id->get<std::string>();
+ std::string tmp = id->get<std::string>();
+ if (!tmp.empty()) // empty group is reserved
+ group = tmp;
}
}
if (cachedGroup && group == lastGroup) {
hits++;
+ lastMsg = thisMsg;
return *cachedGroup;
}