[389-commits] Branch '389-ds-base-1.3.2' - ldap/servers

Mark Reynolds mreynolds at fedoraproject.org
Thu Jan 23 19:58:05 UTC 2014


 ldap/servers/plugins/uiduniq/7bit.c |    8 ++++----
 1 file changed, 4 insertions(+), 4 deletions(-)

New commits:
commit 628cb9073b7a46f867f185ec3e9bb0a16aaf2708
Author: Mark Reynolds <mreynolds at redhat.com>
Date:   Wed Jan 22 11:08:18 2014 -0500

    Ticket 47641 - 7-bit check plugin not checking MODRDN operation
    
    Bug Description:  7-bit check is not being performed on modrdn operations.
    
    Fix Description:  The "superior" DN was not properly being checked/set, and
                      caused the 7-bit check to be skipped.
    
    https://fedorahosted.org/389/ticket/47641
    
    Reviewed by: nhosoi(Thanks!)
    (cherry picked from commit ddbec8c4cea448b775e3848c328cb86b238fe35f)

diff --git a/ldap/servers/plugins/uiduniq/7bit.c b/ldap/servers/plugins/uiduniq/7bit.c
index b6d164b..3474bf9 100644
--- a/ldap/servers/plugins/uiduniq/7bit.c
+++ b/ldap/servers/plugins/uiduniq/7bit.c
@@ -561,7 +561,7 @@ preop_modrdn(Slapi_PBlock *pb)
     char **argv;
     char **attrName;
     Slapi_DN *target_sdn = NULL;
-    Slapi_DN *superior;
+    Slapi_DN *superior = NULL;
     char *rdn; 
     Slapi_Attr *attr;
     char **firstSubtree;
@@ -601,7 +601,7 @@ preop_modrdn(Slapi_PBlock *pb)
      * its current level in the tree.  Use the target DN for
      * determining which managed tree this belongs to
      */
-    if (!superior) superior = target_sdn;
+    if (!slapi_sdn_get_dn(superior)) superior = target_sdn;
 
     /* Get the new RDN - this has the attribute values */
     err = slapi_pblock_get(pb, SLAPI_MODRDN_NEWRDN, &rdn);
@@ -635,7 +635,7 @@ preop_modrdn(Slapi_PBlock *pb)
     }
 
     /*
-     * arguments before "," are the 7-bit clean attribute names.  Arguemnts
+     * arguments before "," are the 7-bit clean attribute names.  Arguments
      * after "," are subtreeDN's.
      */
     for ( firstSubtree = argv; strcmp(*firstSubtree, ",") != 0;
@@ -650,7 +650,7 @@ preop_modrdn(Slapi_PBlock *pb)
     for (attrName = argv; strcmp(*attrName, ",") != 0; attrName++ )
     {
       /* 
-       * If the attribut type is userpassword, do not replace it by 
+       * If the attribute type is userpassword, do not replace it by
        * unhashed#user#password because unhashed#user#password does not exist  
        * in this case.
        */




More information about the 389-commits mailing list