camel-commits mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From davscl...@apache.org
Subject svn commit: r1227071 - in /camel/branches/camel-2.8.x: ./ camel-core/src/main/java/org/apache/camel/builder/xml/MessageVariableResolver.java
Date Wed, 04 Jan 2012 08:21:10 GMT
Author: davsclaus
Date: Wed Jan  4 08:21:09 2012
New Revision: 1227071

URL: http://svn.apache.org/viewvc?rev=1227071&view=rev
Log:
CAMEL-4858: XPathBuilder variable resolver for $ should return empty string if no header to
support both JDK and Saxon XPath Engines.

Modified:
    camel/branches/camel-2.8.x/   (props changed)
    camel/branches/camel-2.8.x/camel-core/src/main/java/org/apache/camel/builder/xml/MessageVariableResolver.java

Propchange: camel/branches/camel-2.8.x/
------------------------------------------------------------------------------
--- svn:mergeinfo (original)
+++ svn:mergeinfo Wed Jan  4 08:21:09 2012
@@ -1 +1 @@
-/camel/trunk:1212504,1215477,1221565,1224674,1225077-1225078,1225766,1226081,1226387,1226430,1226867,1227046
+/camel/trunk:1212504,1215477,1221565,1224674,1225077-1225078,1225766,1226081,1226387,1226430,1226867,1227046,1227068

Propchange: camel/branches/camel-2.8.x/
------------------------------------------------------------------------------
Binary property 'svnmerge-integrated' - no diff available.

Modified: camel/branches/camel-2.8.x/camel-core/src/main/java/org/apache/camel/builder/xml/MessageVariableResolver.java
URL: http://svn.apache.org/viewvc/camel/branches/camel-2.8.x/camel-core/src/main/java/org/apache/camel/builder/xml/MessageVariableResolver.java?rev=1227071&r1=1227070&r2=1227071&view=diff
==============================================================================
--- camel/branches/camel-2.8.x/camel-core/src/main/java/org/apache/camel/builder/xml/MessageVariableResolver.java
(original)
+++ camel/branches/camel-2.8.x/camel-core/src/main/java/org/apache/camel/builder/xml/MessageVariableResolver.java
Wed Jan  4 08:21:09 2012
@@ -94,10 +94,10 @@ public class MessageVariableResolver imp
             }
         }
 
-        // If we can't find an answer we must return void.
-        // We can't return null then the xpath engine will throw a NullPointerException
+        // if we can't find an answer we must return an empty String.
+        // if we return null, then the JDK default XPathEngine will throw an exception
         if (answer == null) {
-            return Void.class;
+            return "";
         } else {
             return answer;
         }



Mime
View raw message