mirror of
https://git.openldap.org/openldap/openldap.git
synced 2024-12-21 03:10:25 +08:00
Use individual addAttrDN, compareAttrDN, modifyAttrDN, searchAttrDN contexts
instead of re-using other contexts.
This commit is contained in:
parent
8ef3bbb174
commit
c823f9a995
@ -95,6 +95,9 @@ ldap_back_add(
|
||||
/* Create array of LDAPMods for ldap_add() */
|
||||
attrs = (LDAPMod **)ch_malloc(sizeof(LDAPMod *)*i);
|
||||
|
||||
#ifdef ENABLE_REWRITE
|
||||
dc.ctx = "addAttrDN";
|
||||
#endif
|
||||
for (i=0, a=op->oq_add.rs_e->e_attrs; a; a=a->a_next) {
|
||||
if ( a->a_desc->ad_type->sat_no_user_mod ) {
|
||||
continue;
|
||||
@ -154,9 +157,6 @@ ldap_dnattr_rewrite(
|
||||
{
|
||||
struct berval bv;
|
||||
|
||||
#ifdef ENABLE_REWRITE
|
||||
dc->ctx="dnAttr";
|
||||
#endif
|
||||
for ( ; a_vals->bv_val != NULL; a_vals++ ) {
|
||||
ldap_back_dn_massage( dc, a_vals, &bv );
|
||||
|
||||
|
@ -95,7 +95,7 @@ ldap_back_compare(
|
||||
}
|
||||
if (op->orc_ava->aa_desc->ad_type->sat_syntax == slap_schema.si_syn_distinguishedName ) {
|
||||
#ifdef ENABLE_REWRITE
|
||||
dc.ctx = "dnAttr";
|
||||
dc.ctx = "compareAttrDN";
|
||||
#endif
|
||||
ldap_back_dn_massage( &dc, &op->orc_ava->aa_value, &mapped_val );
|
||||
if (mapped_val.bv_val == NULL || mapped_val.bv_val[0] == '\0') {
|
||||
|
@ -97,6 +97,9 @@ ldap_back_modify(
|
||||
goto cleanup;
|
||||
}
|
||||
|
||||
#ifdef ENABLE_REWRITE
|
||||
dc.ctx = "modifyAttrDN";
|
||||
#endif
|
||||
for (i=0, ml=op->oq_modify.rs_modlist; ml; ml=ml->sml_next) {
|
||||
if ( ml->sml_desc->ad_type->sat_no_user_mod ) {
|
||||
continue;
|
||||
|
@ -421,6 +421,9 @@ ldap_build_entry(
|
||||
ent->e_private = 0;
|
||||
attrp = &ent->e_attrs;
|
||||
|
||||
#ifdef ENABLE_REWRITE
|
||||
dc.ctx = "searchAttrDN";
|
||||
#endif
|
||||
while ( ber_scanf( &ber, "{m", &a ) != LBER_ERROR ) {
|
||||
ldap_back_map(&li->at_map, &a, &mapped, BACKLDAP_REMAP);
|
||||
if (mapped.bv_val == NULL || mapped.bv_val[0] == '\0')
|
||||
|
Loading…
Reference in New Issue
Block a user