diff options
| author | Rajith Muditha Attapattu <rajith@apache.org> | 2013-03-26 21:29:45 +0000 |
|---|---|---|
| committer | Rajith Muditha Attapattu <rajith@apache.org> | 2013-03-26 21:29:45 +0000 |
| commit | f08d757099b0c25a67353a06cd2c7706cbee701d (patch) | |
| tree | af253a2a3f849a54cfea29705a7c668f53c91164 /qpid/java/client | |
| parent | 459a22d3a7449e2f375f01177891bf59cf914bb4 (diff) | |
| download | qpid-python-f08d757099b0c25a67353a06cd2c7706cbee701d.tar.gz | |
QPID-3769 Added a check to see if the subject is equal.
git-svn-id: https://svn.apache.org/repos/asf/qpid/trunk@1461324 13f79535-47bb-0310-9956-ffa450edef68
Diffstat (limited to 'qpid/java/client')
| -rw-r--r-- | qpid/java/client/src/main/java/org/apache/qpid/client/AMQDestination.java | 15 |
1 files changed, 15 insertions, 0 deletions
diff --git a/qpid/java/client/src/main/java/org/apache/qpid/client/AMQDestination.java b/qpid/java/client/src/main/java/org/apache/qpid/client/AMQDestination.java index 6ca2988186..fc7762e77d 100644 --- a/qpid/java/client/src/main/java/org/apache/qpid/client/AMQDestination.java +++ b/qpid/java/client/src/main/java/org/apache/qpid/client/AMQDestination.java @@ -653,6 +653,17 @@ public abstract class AMQDestination implements Destination, Referenceable { return false; } + if (_subject == null) + { + if (that.getSubject() != null) + { + return false; + } + } + else if (!_subject.equals(that.getSubject())) + { + return false; + } } else { @@ -679,6 +690,10 @@ public abstract class AMQDestination implements Destination, Referenceable if (_destSyntax == DestSyntax.ADDR) { result = 29 * _addressType + _name.hashCode(); + if (_subject != null) + { + result = 29 * result + _subject.hashCode(); + } } else { |
