You are viewing a plain text version of this content. The canonical link for it is here.
Posted to commits@camel.apache.org by da...@apache.org on 2015/03/04 11:08:32 UTC

[1/2] camel git commit: Skip ftp tests which cannot test on windows.

Repository: camel
Updated Branches:
  refs/heads/master 15174ce7b -> eaa06ef28


Skip ftp tests which cannot test on windows.


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

Branch: refs/heads/master
Commit: eaa06ef28836390abafdd22e63e2b628d3f7d7a5
Parents: a8fd547
Author: Claus Ibsen <da...@apache.org>
Authored: Wed Mar 4 11:09:40 2015 +0100
Committer: Claus Ibsen <da...@apache.org>
Committed: Wed Mar 4 11:09:49 2015 +0100

----------------------------------------------------------------------
 .../file/remote/sftp/SftpSimpleConsumeAbsoluteTest.java  | 11 ++++++-----
 1 file changed, 6 insertions(+), 5 deletions(-)
----------------------------------------------------------------------


http://git-wip-us.apache.org/repos/asf/camel/blob/eaa06ef2/components/camel-ftp/src/test/java/org/apache/camel/component/file/remote/sftp/SftpSimpleConsumeAbsoluteTest.java
----------------------------------------------------------------------
diff --git a/components/camel-ftp/src/test/java/org/apache/camel/component/file/remote/sftp/SftpSimpleConsumeAbsoluteTest.java b/components/camel-ftp/src/test/java/org/apache/camel/component/file/remote/sftp/SftpSimpleConsumeAbsoluteTest.java
index c83829a..44bb898 100644
--- a/components/camel-ftp/src/test/java/org/apache/camel/component/file/remote/sftp/SftpSimpleConsumeAbsoluteTest.java
+++ b/components/camel-ftp/src/test/java/org/apache/camel/component/file/remote/sftp/SftpSimpleConsumeAbsoluteTest.java
@@ -26,13 +26,14 @@ import org.junit.Test;
  */
 public class SftpSimpleConsumeAbsoluteTest extends SftpServerTestSupport {
 
+    @Override
+    protected boolean canTest() {
+        // cannot test on windows
+        return super.canTest() && !isPlatform("windows");
+    }
+
     protected static String createAbsolutePath() {
         String answer = System.getProperty("user.dir") + "/" + FTP_ROOT_DIR + "/tmp/mytemp";
-
-        if (isPlatform("windows")) {
-            answer = answer.replace('\\', '/');
-        }
-
         return answer;
     }
 


[2/2] camel git commit: Fixed potential NPE

Posted by da...@apache.org.
Fixed potential NPE


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

Branch: refs/heads/master
Commit: a8fd547fbc63429831be89b5f5566334bd9b4358
Parents: 15174ce
Author: Claus Ibsen <da...@apache.org>
Authored: Wed Mar 4 11:08:31 2015 +0100
Committer: Claus Ibsen <da...@apache.org>
Committed: Wed Mar 4 11:09:49 2015 +0100

----------------------------------------------------------------------
 .../main/java/org/apache/camel/impl/ScheduledPollConsumer.java | 6 ++++--
 1 file changed, 4 insertions(+), 2 deletions(-)
----------------------------------------------------------------------


http://git-wip-us.apache.org/repos/asf/camel/blob/a8fd547f/camel-core/src/main/java/org/apache/camel/impl/ScheduledPollConsumer.java
----------------------------------------------------------------------
diff --git a/camel-core/src/main/java/org/apache/camel/impl/ScheduledPollConsumer.java b/camel-core/src/main/java/org/apache/camel/impl/ScheduledPollConsumer.java
index beac5bf..5f25a4f 100644
--- a/camel-core/src/main/java/org/apache/camel/impl/ScheduledPollConsumer.java
+++ b/camel-core/src/main/java/org/apache/camel/impl/ScheduledPollConsumer.java
@@ -458,8 +458,10 @@ public abstract class ScheduledPollConsumer extends DefaultConsumer implements R
 
     @Override
     protected void doStop() throws Exception {
-        scheduler.unscheduleTask();
-        ServiceHelper.stopAndShutdownServices(scheduler);
+        if (scheduler != null) {
+            scheduler.unscheduleTask();
+            ServiceHelper.stopAndShutdownServices(scheduler);
+        }
 
         // clear counters
         backoffCounter = 0;