directory-commits mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From pamarce...@apache.org
Subject svn commit: r1028798 - /directory/studio/branches/studio-connection-refactoring/plugins/connection.core/src/main/java/org/apache/directory/studio/connection/core/io/api/DirectoryApiConnectionWrapper.java
Date Fri, 29 Oct 2010 15:12:15 GMT
Author: pamarcelot
Date: Fri Oct 29 15:12:14 2010
New Revision: 1028798

URL: http://svn.apache.org/viewvc?rev=1028798&view=rev
Log:
Corrected the execution (connect() then startTls()).

Modified:
    directory/studio/branches/studio-connection-refactoring/plugins/connection.core/src/main/java/org/apache/directory/studio/connection/core/io/api/DirectoryApiConnectionWrapper.java

Modified: directory/studio/branches/studio-connection-refactoring/plugins/connection.core/src/main/java/org/apache/directory/studio/connection/core/io/api/DirectoryApiConnectionWrapper.java
URL: http://svn.apache.org/viewvc/directory/studio/branches/studio-connection-refactoring/plugins/connection.core/src/main/java/org/apache/directory/studio/connection/core/io/api/DirectoryApiConnectionWrapper.java?rev=1028798&r1=1028797&r2=1028798&view=diff
==============================================================================
--- directory/studio/branches/studio-connection-refactoring/plugins/connection.core/src/main/java/org/apache/directory/studio/connection/core/io/api/DirectoryApiConnectionWrapper.java
(original)
+++ directory/studio/branches/studio-connection-refactoring/plugins/connection.core/src/main/java/org/apache/directory/studio/connection/core/io/api/DirectoryApiConnectionWrapper.java
Fri Oct 29 15:12:14 2010
@@ -213,16 +213,18 @@ public class DirectoryApiConnectionWrapp
             {
                 try
                 {
-                    if ( connection.getConnectionParameter().getEncryptionMethod() == ConnectionParameter.EncryptionMethod.START_TLS
)
-                    {
-                        getLdapConnection().startTls();
-                    }
-
+                    // Connecting
                     boolean connected = getLdapConnection().connect();
                     if ( !connected )
                     {
                         throw new Exception( "Unable to connect" );
                     }
+
+                    // Start TLS
+                    if ( connection.getConnectionParameter().getEncryptionMethod() == ConnectionParameter.EncryptionMethod.START_TLS
)
+                    {
+                        getLdapConnection().startTls();
+                    }
                 }
                 catch ( Exception e )
                 {



Mime
View raw message