[exo-jcr-commits] exo-jcr SVN: r2437 - jcr/trunk/exo.jcr.component.ftp/src/main/java/org/exoplatform/services/ftp/client.

do-not-reply at jboss.org do-not-reply at jboss.org
Wed May 26 09:39:20 EDT 2010


Author: tolusha
Date: 2010-05-26 09:39:19 -0400 (Wed, 26 May 2010)
New Revision: 2437

Modified:
   jcr/trunk/exo.jcr.component.ftp/src/main/java/org/exoplatform/services/ftp/client/FtpClientSessionImpl.java
Log:
EXOJCR-736: Problems with anonymous entrance on FTP and NPE

Modified: jcr/trunk/exo.jcr.component.ftp/src/main/java/org/exoplatform/services/ftp/client/FtpClientSessionImpl.java
===================================================================
--- jcr/trunk/exo.jcr.component.ftp/src/main/java/org/exoplatform/services/ftp/client/FtpClientSessionImpl.java	2010-05-26 13:26:50 UTC (rev 2436)
+++ jcr/trunk/exo.jcr.component.ftp/src/main/java/org/exoplatform/services/ftp/client/FtpClientSessionImpl.java	2010-05-26 13:39:19 UTC (rev 2437)
@@ -417,6 +417,11 @@
       ExoContainer container = ExoContainerContext.getCurrentContainer();
       IdentityRegistry identityRegistry =
          (IdentityRegistry)container.getComponentInstanceOfType(IdentityRegistry.class);
-      identityRegistry.unregister(this.userId);
+
+      // The check need for case when login failed
+      if (this.userId != null)
+      {
+         identityRegistry.unregister(this.userId);
+      }
    }
 }



More information about the exo-jcr-commits mailing list