Skip to content
Snippets Groups Projects
Commit ac7ac5ac authored by Luke Howard's avatar Luke Howard
Browse files

Don't crash if attr_find() fails (Howard, you might like to review this)

parent eed45f45
No related branches found
No related tags found
No related merge requests found
......@@ -240,9 +240,13 @@ int bdb_modify_internal(
/* A nullified replace still does its delete action */
case LDAP_MOD_REPLACE | NULLIFIED:
ap = attr_find( save_attrs, ml->sml_desc );
rc = bdb_index_values( op, tid, ap->a_desc,
ap->a_nvals,
e->e_id, SLAP_INDEX_DELETE_OP );
if ( ap != NULL ) {
rc = bdb_index_values( op, tid, ap->a_desc,
ap->a_nvals,
e->e_id, SLAP_INDEX_DELETE_OP );
} else {
rc = LDAP_SUCCESS;
}
if ( rc || ml->sml_op == LDAP_MOD_DELETE ||
(ml->sml_op & NULLIFIED))
break;
......
0% Loading or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment