From: Howard Chu Date: Wed, 28 Sep 2005 16:08:01 +0000 (+0000) Subject: Fix prev commit, reset parent == slap_entry_root X-Git-Tag: OPENLDAP_REL_ENG_2_2_MP~363 X-Git-Url: https://git.sur5r.net/?a=commitdiff_plain;h=17694858682f118fe76787a850cddb99313942b3;p=openldap Fix prev commit, reset parent == slap_entry_root --- diff --git a/servers/slapd/back-ldbm/modrdn.c b/servers/slapd/back-ldbm/modrdn.c index 5f4478d5da..a88da9c518 100644 --- a/servers/slapd/back-ldbm/modrdn.c +++ b/servers/slapd/back-ldbm/modrdn.c @@ -163,10 +163,15 @@ ldbm_back_modrdn( } /* check parent for "children" acl */ - if ( ! access_allowed( op, p, children, NULL, + rs->sr_err = access_allowed( op, p, children, NULL, op->oq_modrdn.rs_newSup != NULL ? ACL_WDEL : ACL_WRITE, - NULL ) ) + NULL ); + + if ( BER_BVISEMPTY( &p_ndn )) + p = NULL; + + if ( !rs->sr_err ) { Debug( LDAP_DEBUG_TRACE, "no access to parent\n", 0, 0, 0 ); @@ -176,9 +181,6 @@ ldbm_back_modrdn( goto return_results; } - if ( BER_BVISEMPTY( &p_ndn )) - p = NULL; - Debug( LDAP_DEBUG_TRACE, "ldbm_back_modrdn: wr to children of entry %s OK\n", p_ndn.bv_val, 0, 0 );