You are viewing a plain text version of this content. The canonical link for it is here.
Posted to commits@camel.apache.org by gg...@apache.org on 2015/04/29 12:23:13 UTC

camel git commit: [CAMEL-8718] Do not disconnect if connected & logged in

Repository: camel
Updated Branches:
  refs/heads/master e129b88c2 -> 555347496


[CAMEL-8718] Do not disconnect if connected & logged in


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

Branch: refs/heads/master
Commit: 5553474960c83ed8828ed252031818c050a6436f
Parents: e129b88
Author: Grzegorz Grzybek <gr...@gmail.com>
Authored: Wed Apr 29 12:22:58 2015 +0200
Committer: Grzegorz Grzybek <gr...@gmail.com>
Committed: Wed Apr 29 12:22:58 2015 +0200

----------------------------------------------------------------------
 .../org/apache/camel/component/file/remote/RemoteFileConsumer.java | 2 +-
 1 file changed, 1 insertion(+), 1 deletion(-)
----------------------------------------------------------------------


http://git-wip-us.apache.org/repos/asf/camel/blob/55534749/components/camel-ftp/src/main/java/org/apache/camel/component/file/remote/RemoteFileConsumer.java
----------------------------------------------------------------------
diff --git a/components/camel-ftp/src/main/java/org/apache/camel/component/file/remote/RemoteFileConsumer.java b/components/camel-ftp/src/main/java/org/apache/camel/component/file/remote/RemoteFileConsumer.java
index ad27000..bf28f14 100644
--- a/components/camel-ftp/src/main/java/org/apache/camel/component/file/remote/RemoteFileConsumer.java
+++ b/components/camel-ftp/src/main/java/org/apache/camel/component/file/remote/RemoteFileConsumer.java
@@ -198,7 +198,7 @@ public abstract class RemoteFileConsumer<T> extends GenericFileConsumer<T> {
 
         try {
             // we may as well be connected, but not logged in. let's disconnect to prevent connection leak
-            if (getOperations().isConnected()) {
+            if (!isConnected && getOperations().isConnected()) {
                 getOperations().disconnect();
             }
         } catch (Exception ex) {