summaryrefslogtreecommitdiff
path: root/cpp/src/qpid/broker/Queue.cpp
diff options
context:
space:
mode:
authorGordon Sim <gsim@apache.org>2013-06-25 13:28:15 +0000
committerGordon Sim <gsim@apache.org>2013-06-25 13:28:15 +0000
commit35cb597c315b5bc3e17611cb40fe8492b0a4e45c (patch)
tree39d79c9ec301089de7b4471d23245f92bf10a0d1 /cpp/src/qpid/broker/Queue.cpp
parent167069c6d6eb3ca2c5f997cbb16f296302160ad7 (diff)
downloadqpid-python-35cb597c315b5bc3e17611cb40fe8492b0a4e45c.tar.gz
QPID-4712: authorisation for AMQP 1.0 connections
git-svn-id: https://svn.apache.org/repos/asf/qpid/trunk/qpid@1496466 13f79535-47bb-0310-9956-ffa450edef68
Diffstat (limited to 'cpp/src/qpid/broker/Queue.cpp')
-rw-r--r--cpp/src/qpid/broker/Queue.cpp7
1 files changed, 1 insertions, 6 deletions
diff --git a/cpp/src/qpid/broker/Queue.cpp b/cpp/src/qpid/broker/Queue.cpp
index e1782b01ce..c402e3e016 100644
--- a/cpp/src/qpid/broker/Queue.cpp
+++ b/cpp/src/qpid/broker/Queue.cpp
@@ -220,18 +220,13 @@ Queue::~Queue()
{
}
-bool isLocalTo(const OwnershipToken* token, const Message& msg)
-{
- return token && token->isLocal(msg.getPublisherOwnership());
-}
-
bool Queue::isLocal(const Message& msg)
{
//message is considered local if it was published on the same
//connection as that of the session which declared this queue
//exclusive (owner) or which has an exclusive subscription
//(exclusive)
- return settings.noLocal && (isLocalTo(owner, msg) || isLocalTo(exclusive, msg));
+ return settings.noLocal && (msg.isLocalTo(owner) || msg.isLocalTo(exclusive));
}
bool Queue::isExcluded(const Message& msg)