camel-commits mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From davscl...@apache.org
Subject svn commit: r1328393 - in /camel/branches/camel-2.9.x: ./ camel-core/src/main/java/org/apache/camel/builder/xml/ camel-core/src/test/java/org/apache/camel/component/xslt/ camel-core/src/test/resources/org/apache/camel/component/xslt/
Date Fri, 20 Apr 2012 15:02:41 GMT
Author: davsclaus
Date: Fri Apr 20 15:02:41 2012
New Revision: 1328393

URL: http://svn.apache.org/viewvc?rev=1328393&view=rev
Log:
CAMEL-5195: Fixed issue with xsl:include should use / as class path separator.

Added:
    camel/branches/camel-2.9.x/camel-core/src/test/java/org/apache/camel/component/xslt/XsltIncludeClasspathDotInDirectoryTest.java
      - copied unchanged from r1328392, camel/trunk/camel-core/src/test/java/org/apache/camel/component/xslt/XsltIncludeClasspathDotInDirectoryTest.java
    camel/branches/camel-2.9.x/camel-core/src/test/resources/org/apache/camel/component/xslt/staff_include_classpath2.xsl
      - copied unchanged from r1328392, camel/trunk/camel-core/src/test/resources/org/apache/camel/component/xslt/staff_include_classpath2.xsl
Modified:
    camel/branches/camel-2.9.x/   (props changed)
    camel/branches/camel-2.9.x/camel-core/src/main/java/org/apache/camel/builder/xml/XsltUriResolver.java

Propchange: camel/branches/camel-2.9.x/
------------------------------------------------------------------------------
  Merged /camel/trunk:r1328392

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

Modified: camel/branches/camel-2.9.x/camel-core/src/main/java/org/apache/camel/builder/xml/XsltUriResolver.java
URL: http://svn.apache.org/viewvc/camel/branches/camel-2.9.x/camel-core/src/main/java/org/apache/camel/builder/xml/XsltUriResolver.java?rev=1328393&r1=1328392&r2=1328393&view=diff
==============================================================================
--- camel/branches/camel-2.9.x/camel-core/src/main/java/org/apache/camel/builder/xml/XsltUriResolver.java
(original)
+++ camel/branches/camel-2.9.x/camel-core/src/main/java/org/apache/camel/builder/xml/XsltUriResolver.java
Fri Apr 20 15:02:41 2012
@@ -76,6 +76,9 @@ public class XsltUriResolver implements 
 
             String name = ObjectHelper.after(href, ":");
             File file = new File(name);
+            if (!file.exists()) {
+                throw new TransformerException("Cannot find " + name + " in the file system");
+            }
             return new StreamSource(file);
         }
 
@@ -87,7 +90,7 @@ public class XsltUriResolver implements 
             return resolve(path, base);
         } else {
             // default to use classpath: location
-            path = "classpath:" + path + File.separator + href;
+            path = "classpath:" + path + "/" + href;
             return resolve(path, base);
         }
     }



Mime
View raw message