directory-commits mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From seelm...@apache.org
Subject svn commit: r613680 - in /directory/studio/trunk/studio-connection-core/src/main/java/org/apache/directory/studio/connection/core: IAuthHandler.java io/jndi/JNDIConnectionWrapper.java
Date Sun, 20 Jan 2008 21:16:04 GMT
Author: seelmann
Date: Sun Jan 20 13:16:03 2008
New Revision: 613680

URL: http://svn.apache.org/viewvc?rev=613680&view=rev
Log:
Fixed exception when canceling the authtification.

Modified:
    directory/studio/trunk/studio-connection-core/src/main/java/org/apache/directory/studio/connection/core/IAuthHandler.java
    directory/studio/trunk/studio-connection-core/src/main/java/org/apache/directory/studio/connection/core/io/jndi/JNDIConnectionWrapper.java

Modified: directory/studio/trunk/studio-connection-core/src/main/java/org/apache/directory/studio/connection/core/IAuthHandler.java
URL: http://svn.apache.org/viewvc/directory/studio/trunk/studio-connection-core/src/main/java/org/apache/directory/studio/connection/core/IAuthHandler.java?rev=613680&r1=613679&r2=613680&view=diff
==============================================================================
--- directory/studio/trunk/studio-connection-core/src/main/java/org/apache/directory/studio/connection/core/IAuthHandler.java
(original)
+++ directory/studio/trunk/studio-connection-core/src/main/java/org/apache/directory/studio/connection/core/IAuthHandler.java
Sun Jan 20 13:16:03 2008
@@ -37,7 +37,7 @@
      * The authentication handler may display a dialog to the user.
      * 
      * @param connectionParameter the connection to bind to
-     * @return the credentials
+     * @return the credentials, null to cancel the authentication
      */
     public ICredentials getCredentials( ConnectionParameter connectionParameter );
 

Modified: directory/studio/trunk/studio-connection-core/src/main/java/org/apache/directory/studio/connection/core/io/jndi/JNDIConnectionWrapper.java
URL: http://svn.apache.org/viewvc/directory/studio/trunk/studio-connection-core/src/main/java/org/apache/directory/studio/connection/core/io/jndi/JNDIConnectionWrapper.java?rev=613680&r1=613679&r2=613680&view=diff
==============================================================================
--- directory/studio/trunk/studio-connection-core/src/main/java/org/apache/directory/studio/connection/core/io/jndi/JNDIConnectionWrapper.java
(original)
+++ directory/studio/trunk/studio-connection-core/src/main/java/org/apache/directory/studio/connection/core/io/jndi/JNDIConnectionWrapper.java
Sun Jan 20 13:16:03 2008
@@ -856,7 +856,9 @@
             ICredentials credentials = authHandler.getCredentials( connection.getConnectionParameter()
);
             if ( credentials == null )
             {
-                monitor.reportError( Messages.model__no_credentials, new Exception() );
+                monitor.setCanceled( true );
+                monitor.reportError( Messages.model__no_credentials, new CancelException()
);
+                throw new CancelException();
             }
             bindPrincipal = credentials.getBindPrincipal();
             bindCredentials = credentials.getBindPassword();



Mime
View raw message