mirror of https://github.com/OpenIdentityPlatform/OpenDJ.git

Nicolas Capponi
12.55.2014 39be274a446bc48400fb0f4ff8ec74b54883f7a6
opendj3-server-dev/src/server/org/opends/server/tools/LDAPCompare.java
@@ -40,7 +40,6 @@
import org.opends.admin.ads.util.ConnectionUtils;
import org.forgerock.i18n.LocalizableMessage;
import org.opends.server.controls.LDAPAssertionRequestControl;
import org.forgerock.i18n.slf4j.LocalizedLogger;
import org.forgerock.opendj.ldap.DecodeException;
import org.opends.server.protocols.ldap.CompareRequestProtocolOp;
import org.opends.server.protocols.ldap.CompareResponseProtocolOp;
@@ -52,6 +51,7 @@
import org.opends.server.util.Base64;
import org.opends.server.util.EmbeddedUtils;
import org.opends.server.util.PasswordReader;
import com.forgerock.opendj.cli.ArgumentException;
import com.forgerock.opendj.cli.ArgumentParser;
import com.forgerock.opendj.cli.BooleanArgument;
@@ -72,8 +72,6 @@
 */
public class LDAPCompare
{
  private static final LocalizedLogger logger = LocalizedLogger.getLoggerForThisClass();
  /**
   * The fully-qualified name of this class.
   */
@@ -250,7 +248,6 @@
        responseMessage = connection.getLDAPReader().readMessage();
      } catch(DecodeException ae)
      {
        logger.traceException(ae);
        if (!compareOptions.continueOnError())
        {
          String message = LDAPToolUtils.getMessageForConnectionException(ae);
@@ -752,11 +749,10 @@
        }
        catch (ParseException e)
        {
          logger.traceException(e);
          err.println(wrapText(
                  INFO_COMPARE_CANNOT_BASE64_DECODE_ASSERTION_VALUE.get(),
                  MAX_LINE_WIDTH));
          err.println(wrapText(e.getLocalizedMessage(), MAX_LINE_WIDTH));
          return CLIENT_SIDE_PARAM_ERROR;
        }
      } else if(nextChar == '<')
@@ -790,7 +786,6 @@
      portNumber = port.getIntValue();
    } catch (ArgumentException ae)
    {
      logger.traceException(ae);
      err.println(wrapText(ae.getMessage(), MAX_LINE_WIDTH));
      return CLIENT_SIDE_PARAM_ERROR;
    }
@@ -806,7 +801,6 @@
      connectionOptions.setVersionNumber(versionNumber);
    } catch(ArgumentException ae)
    {
      logger.traceException(ae);
      err.println(wrapText(ae.getMessage(), MAX_LINE_WIDTH));
      return CLIENT_SIDE_PARAM_ERROR;
    }
@@ -838,7 +832,6 @@
        bindPasswordValue = new String(pwChars);
      } catch(Exception ex)
      {
        logger.traceException(ex);
        err.println(wrapText(ex.getMessage(), MAX_LINE_WIDTH));
        return CLIENT_SIDE_PARAM_ERROR;
      }
@@ -1009,7 +1002,6 @@
        }
        catch (Throwable t)
        {
          logger.traceException(t);
          String details = t.getMessage();
          if (details == null)
          {
@@ -1040,7 +1032,6 @@
      return SUCCESS;
    } catch(LDAPException le)
    {
      logger.traceException(le);
      LDAPToolUtils.printErrorMessage(
              err, le.getMessageObject(),
              le.getResultCode(),
@@ -1050,7 +1041,6 @@
      return code;
    } catch(LDAPConnectionException lce)
    {
      logger.traceException(lce);
      LDAPToolUtils.printErrorMessage(err,
                                      lce.getMessageObject(),
                                      lce.getResultCode(),
@@ -1060,7 +1050,6 @@
      return code;
    } catch(Exception e)
    {
      logger.traceException(e);
      err.println(wrapText(e.getMessage(), MAX_LINE_WIDTH));
      return OPERATIONS_ERROR;
    } finally