camel-commits mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From davscl...@apache.org
Subject [6/7] camel git commit: Add null handling
Date Wed, 22 Mar 2017 20:43:02 GMT
Add null handling

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

Branch: refs/heads/camel-2.18.x
Commit: f9efa5bb2bc678df3b71afc5e755a2be066ee8d9
Parents: 06cbd98
Author: hauler <rkalashnikov@gmail.com>
Authored: Thu Mar 16 17:46:44 2017 +0300
Committer: Claus Ibsen <davsclaus@apache.org>
Committed: Wed Mar 22 21:32:47 2017 +0100

----------------------------------------------------------------------
 .../apache/camel/component/rabbitmq/RabbitMQMessagePublisher.java  | 2 +-
 1 file changed, 1 insertion(+), 1 deletion(-)
----------------------------------------------------------------------


http://git-wip-us.apache.org/repos/asf/camel/blob/f9efa5bb/components/camel-rabbitmq/src/main/java/org/apache/camel/component/rabbitmq/RabbitMQMessagePublisher.java
----------------------------------------------------------------------
diff --git a/components/camel-rabbitmq/src/main/java/org/apache/camel/component/rabbitmq/RabbitMQMessagePublisher.java
b/components/camel-rabbitmq/src/main/java/org/apache/camel/component/rabbitmq/RabbitMQMessagePublisher.java
index c7fee3c..876c701 100644
--- a/components/camel-rabbitmq/src/main/java/org/apache/camel/component/rabbitmq/RabbitMQMessagePublisher.java
+++ b/components/camel-rabbitmq/src/main/java/org/apache/camel/component/rabbitmq/RabbitMQMessagePublisher.java
@@ -70,7 +70,7 @@ public class RabbitMQMessagePublisher {
             LOG.debug("Removing the {} header", RabbitMQEndpoint.SERIALIZE_HEADER);
             message.getHeaders().remove(RabbitMQEndpoint.SERIALIZE_HEADER);
         }
-        if (routingKey.startsWith("amq.rabbitmq.reply-to")) {
+        if (routingKey != null && routingKey.startsWith("amq.rabbitmq.reply-to"))
{
             message.setHeader(RabbitMQConstants.EXCHANGE_NAME, ""); // use default exchange
for reply-to messages
         }
 


Mime
View raw message