]> git.sur5r.net Git - openldap/blobdiff - servers/slapd/back-ldbm/alias.c
modify be_referral to use struct berval DNs.
[openldap] / servers / slapd / back-ldbm / alias.c
index 5f44fb48416129d67f43e60c4dfb64d3b135bd5c..f04428ad14f58f56baa45dc7a94e4f8a665eb51d 100644 (file)
@@ -47,7 +47,7 @@ Entry *deref_internal_r(
                || ( alias == NULL && dn_in != NULL ) );
 
        *matched = NULL;
-       *err = LDAP_SUCCESS;
+       *err = LDAP_NO_SUCH_OBJECT;
        *text = NULL;
 
        if( alias == NULL ) {
@@ -264,7 +264,7 @@ static char* get_alias_dn(
        return dn;
 }
 
-char* new_superior(
+static char* new_superior(
        const char *dn,
        const char *oldSup,
        const char *newSup )
@@ -279,8 +279,8 @@ char* new_superior(
 
        newDN = ch_malloc( dnlen - olen + nlen + 1 );
 
-       memcpy( newDN, dn, dnlen - olen );
-       memcpy( &newDN[dnlen - olen], newSup, nlen );
+       AC_MEMCPY( newDN, dn, dnlen - olen );
+       AC_MEMCPY( &newDN[dnlen - olen], newSup, nlen );
        newDN[dnlen - olen + nlen] = '\0';
 
        return newDN;