activemq-commits mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From hadr...@apache.org
Subject [25/25] git commit: https://issues.apache.org/jira/browse/AMQ-4991 - fix npe and reinstate test
Date Thu, 20 Mar 2014 15:59:20 GMT
https://issues.apache.org/jira/browse/AMQ-4991 - fix npe and reinstate test


Project: http://git-wip-us.apache.org/repos/asf/activemq/repo
Commit: http://git-wip-us.apache.org/repos/asf/activemq/commit/aee5ff45
Tree: http://git-wip-us.apache.org/repos/asf/activemq/tree/aee5ff45
Diff: http://git-wip-us.apache.org/repos/asf/activemq/diff/aee5ff45

Branch: refs/heads/activemq-5.9
Commit: aee5ff45f03673a58be6b6121e9b5ca28c34f492
Parents: a84b29a
Author: gtully <gary.tully@gmail.com>
Authored: Fri Jan 24 13:31:44 2014 +0000
Committer: Hadrian Zbarcea <hadrian@apache.org>
Committed: Thu Mar 20 11:35:16 2014 -0400

----------------------------------------------------------------------
 .../java/org/apache/activemq/jms/pool/PooledProducer.java     | 2 +-
 .../JmsSendReceiveTwoConnectionsWithSenderUsingPoolTest.java  | 7 -------
 2 files changed, 1 insertion(+), 8 deletions(-)
----------------------------------------------------------------------


http://git-wip-us.apache.org/repos/asf/activemq/blob/aee5ff45/activemq-jms-pool/src/main/java/org/apache/activemq/jms/pool/PooledProducer.java
----------------------------------------------------------------------
diff --git a/activemq-jms-pool/src/main/java/org/apache/activemq/jms/pool/PooledProducer.java
b/activemq-jms-pool/src/main/java/org/apache/activemq/jms/pool/PooledProducer.java
index 7f54b99..175f74d 100644
--- a/activemq-jms-pool/src/main/java/org/apache/activemq/jms/pool/PooledProducer.java
+++ b/activemq-jms-pool/src/main/java/org/apache/activemq/jms/pool/PooledProducer.java
@@ -86,7 +86,7 @@ public class PooledProducer implements MessageProducer {
         // just in case let only one thread send at once
         synchronized (messageProducer) {
 
-            if (anonymous && !this.destination.equals(destination)) {
+            if (anonymous && this.destination != null && !this.destination.equals(destination))
{
                 throw new UnsupportedOperationException("This producer can only send messages
to: " + this.destination);
             }
 

http://git-wip-us.apache.org/repos/asf/activemq/blob/aee5ff45/activemq-unit-tests/src/test/java/org/apache/activemq/pool/JmsSendReceiveTwoConnectionsWithSenderUsingPoolTest.java
----------------------------------------------------------------------
diff --git a/activemq-unit-tests/src/test/java/org/apache/activemq/pool/JmsSendReceiveTwoConnectionsWithSenderUsingPoolTest.java
b/activemq-unit-tests/src/test/java/org/apache/activemq/pool/JmsSendReceiveTwoConnectionsWithSenderUsingPoolTest.java
index 4d00415..05ba177 100755
--- a/activemq-unit-tests/src/test/java/org/apache/activemq/pool/JmsSendReceiveTwoConnectionsWithSenderUsingPoolTest.java
+++ b/activemq-unit-tests/src/test/java/org/apache/activemq/pool/JmsSendReceiveTwoConnectionsWithSenderUsingPoolTest.java
@@ -44,11 +44,4 @@ public class JmsSendReceiveTwoConnectionsWithSenderUsingPoolTest extends
JmsTopi
         super.tearDown();
         senderConnectionFactory.stop();
     }
-
-    @Override   // TODO remove this method when AMQ-4991 is fixed
-    @Ignore("See AMQ-4991") // Ignore doesn't really work here with JUnit3 runner, just adding
as documentation
-    public void testSendReceive() throws Exception {
-        //super.testSendReceive();
-    }
-
 }


Mime
View raw message