From a417e001ffab4ad542128e3f61aeaf792e3aff19 Mon Sep 17 00:00:00 2001
From: Jean-Noël Rouvignac <jean-noel.rouvignac@forgerock.com>
Date: Fri, 18 Sep 2015 13:59:37 +0000
Subject: [PATCH] AuthPasswordSyntax*.java: Fixed copy/paste bug

---
 opendj-server-legacy/src/main/java/org/opends/server/schema/AuthPasswordSyntax.java |   11 +++++------
 1 files changed, 5 insertions(+), 6 deletions(-)

diff --git a/opendj-server-legacy/src/main/java/org/opends/server/schema/AuthPasswordSyntax.java b/opendj-server-legacy/src/main/java/org/opends/server/schema/AuthPasswordSyntax.java
index 308a2b1..e7c0965 100644
--- a/opendj-server-legacy/src/main/java/org/opends/server/schema/AuthPasswordSyntax.java
+++ b/opendj-server-legacy/src/main/java/org/opends/server/schema/AuthPasswordSyntax.java
@@ -97,14 +97,13 @@
   }
 
   /**
-   * Decodes the provided authentication password value into its component
-   * parts.
+   * Decodes the provided authentication password value into its component parts.
+   * <p>
+   * FIXME this is a duplicate of {@link org.forgerock.opendj.ldap.schema.AuthPasswordSyntaxImplTest}
    *
    * @param  authPasswordValue  The authentication password value to be decoded.
-   *
    * @return  A three-element array, containing the scheme, authInfo, and
    *          authValue components of the given string, in that order.
-   *
    * @throws  DirectoryException  If a problem is encountered while attempting
    *                              to decode the value.
    */
@@ -249,7 +248,7 @@
 
 
     // The authInfo element must consist of at least one character.
-    if (scheme.length() == 0)
+    if (authInfo.length() == 0)
     {
       LocalizableMessage message = ERR_ATTR_SYNTAX_AUTHPW_NO_AUTH_INFO.get();
       throw new DirectoryException(
@@ -306,7 +305,7 @@
 
 
     // The authValue element must consist of at least one character.
-    if (scheme.length() == 0)
+    if (authValue.length() == 0)
     {
       LocalizableMessage message = ERR_ATTR_SYNTAX_AUTHPW_NO_AUTH_VALUE.get();
       throw new DirectoryException(

--
Gitblit v1.10.0