camel-commits mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From ningji...@apache.org
Subject svn commit: r1372247 - in /camel/branches/camel-2.10.x: ./ camel-core/src/main/java/org/apache/camel/component/file/ camel-core/src/test/java/org/apache/camel/component/file/
Date Mon, 13 Aug 2012 02:57:31 GMT
Author: ningjiang
Date: Mon Aug 13 02:57:30 2012
New Revision: 1372247

URL: http://svn.apache.org/viewvc?rev=1372247&view=rev
Log:
Merged revisions 1371570 via svnmerge from 
https://svn.apache.org/repos/asf/camel/trunk

........
  r1371570 | ningjiang | 2012-08-10 12:45:56 +0800 (Fri, 10 Aug 2012) | 1 line
  
  CAMEL-5495 fix the file endpoint issue on Windows
........

Added:
    camel/branches/camel-2.10.x/camel-core/src/test/java/org/apache/camel/component/file/FileRouteOnDosWithNoVolTest.java
      - copied unchanged from r1371570, camel/trunk/camel-core/src/test/java/org/apache/camel/component/file/FileRouteOnDosWithNoVolTest.java
Modified:
    camel/branches/camel-2.10.x/   (props changed)
    camel/branches/camel-2.10.x/camel-core/src/main/java/org/apache/camel/component/file/FileComponent.java
    camel/branches/camel-2.10.x/camel-core/src/main/java/org/apache/camel/component/file/FileEndpoint.java

Propchange: camel/branches/camel-2.10.x/
------------------------------------------------------------------------------
  Merged /camel/trunk:r1371570

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

Modified: camel/branches/camel-2.10.x/camel-core/src/main/java/org/apache/camel/component/file/FileComponent.java
URL: http://svn.apache.org/viewvc/camel/branches/camel-2.10.x/camel-core/src/main/java/org/apache/camel/component/file/FileComponent.java?rev=1372247&r1=1372246&r2=1372247&view=diff
==============================================================================
--- camel/branches/camel-2.10.x/camel-core/src/main/java/org/apache/camel/component/file/FileComponent.java
(original)
+++ camel/branches/camel-2.10.x/camel-core/src/main/java/org/apache/camel/component/file/FileComponent.java
Mon Aug 13 02:57:30 2012
@@ -19,6 +19,7 @@ package org.apache.camel.component.file;
 import java.io.File;
 import java.util.Map;
 
+import org.apache.camel.util.FileUtil;
 import org.apache.camel.util.StringHelper;
 
 /**
@@ -50,7 +51,7 @@ public class FileComponent extends Gener
         result.setFile(file);
 
         GenericFileConfiguration config = new GenericFileConfiguration();
-        config.setDirectory(file.getPath());
+        config.setDirectory(FileUtil.isAbsolute(file) ? file.getAbsolutePath() : file.getPath());
         result.setConfiguration(config);
 
         return result;

Modified: camel/branches/camel-2.10.x/camel-core/src/main/java/org/apache/camel/component/file/FileEndpoint.java
URL: http://svn.apache.org/viewvc/camel/branches/camel-2.10.x/camel-core/src/main/java/org/apache/camel/component/file/FileEndpoint.java?rev=1372247&r1=1372246&r2=1372247&view=diff
==============================================================================
--- camel/branches/camel-2.10.x/camel-core/src/main/java/org/apache/camel/component/file/FileEndpoint.java
(original)
+++ camel/branches/camel-2.10.x/camel-core/src/main/java/org/apache/camel/component/file/FileEndpoint.java
Mon Aug 13 02:57:30 2012
@@ -127,7 +127,7 @@ public class FileEndpoint extends Generi
     public void setFile(File file) {
         this.file = file;
         // update configuration as well
-        getConfiguration().setDirectory(file.getPath());
+        getConfiguration().setDirectory(FileUtil.isAbsolute(file) ? file.getAbsolutePath()
: file.getPath());
     }
 
     @Override



Mime
View raw message