activemq-commits mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From tab...@apache.org
Subject activemq git commit: https://issues.apache.org/jira/browse/AMQ-5629
Date Tue, 03 Mar 2015 21:51:25 GMT
Repository: activemq
Updated Branches:
  refs/heads/master 4b346360b -> 4d5bb4ab7


https://issues.apache.org/jira/browse/AMQ-5629

Fix exception string to reflect type being read.

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

Branch: refs/heads/master
Commit: 4d5bb4ab7b09ba48d605850ab1aaac594bb66f65
Parents: 4b34636
Author: Timothy Bish <tabish121@gmail.com>
Authored: Tue Mar 3 16:51:21 2015 -0500
Committer: Timothy Bish <tabish121@gmail.com>
Committed: Tue Mar 3 16:51:21 2015 -0500

----------------------------------------------------------------------
 .../java/org/apache/activemq/command/ActiveMQMapMessage.java   | 6 +++---
 1 file changed, 3 insertions(+), 3 deletions(-)
----------------------------------------------------------------------


http://git-wip-us.apache.org/repos/asf/activemq/blob/4d5bb4ab/activemq-client/src/main/java/org/apache/activemq/command/ActiveMQMapMessage.java
----------------------------------------------------------------------
diff --git a/activemq-client/src/main/java/org/apache/activemq/command/ActiveMQMapMessage.java
b/activemq-client/src/main/java/org/apache/activemq/command/ActiveMQMapMessage.java
index 7fac237..7d80681 100755
--- a/activemq-client/src/main/java/org/apache/activemq/command/ActiveMQMapMessage.java
+++ b/activemq-client/src/main/java/org/apache/activemq/command/ActiveMQMapMessage.java
@@ -312,13 +312,13 @@ public class ActiveMQMapMessage extends ActiveMQMessage implements MapMessage
{
     public char getChar(String name) throws JMSException {
         initializeReading();
         Object value = map.get(name);
+
         if (value == null) {
             throw new NullPointerException();
-        }
-        if (value instanceof Character) {
+        } else if (value instanceof Character) {
             return ((Character)value).charValue();
         } else {
-            throw new MessageFormatException(" cannot read a short from " + value.getClass().getName());
+            throw new MessageFormatException(" cannot read a char from " + value.getClass().getName());
         }
     }
 


Mime
View raw message