summaryrefslogtreecommitdiff
path: root/cpp/src/qpid/broker/QueueRegistry.h
diff options
context:
space:
mode:
Diffstat (limited to 'cpp/src/qpid/broker/QueueRegistry.h')
-rw-r--r--cpp/src/qpid/broker/QueueRegistry.h5
1 files changed, 4 insertions, 1 deletions
diff --git a/cpp/src/qpid/broker/QueueRegistry.h b/cpp/src/qpid/broker/QueueRegistry.h
index 1a766b810a..f73f467945 100644
--- a/cpp/src/qpid/broker/QueueRegistry.h
+++ b/cpp/src/qpid/broker/QueueRegistry.h
@@ -62,11 +62,14 @@ class QueueRegistry{
*
*/
void destroy(const string& name);
- template <class Test> void destroyIf(const string& name, Test test)
+ template <class Test> bool destroyIf(const string& name, Test test)
{
qpid::sys::RWlock::ScopedWlock locker(lock);
if (test()) {
queues.erase(name);
+ return true;
+ } else {
+ return false;
}
}