From: Pierangelo Masarati Date: Fri, 23 Aug 2002 08:46:45 +0000 (+0000) Subject: added assertions to catch helper function misuse X-Git-Tag: NO_SLAP_OP_BLOCKS~1198 X-Git-Url: https://git.sur5r.net/?a=commitdiff_plain;h=ff4edfa0544e54b10bbc9c1c35dc0338ad2687e8;p=openldap added assertions to catch helper function misuse --- diff --git a/servers/slapd/modrdn.c b/servers/slapd/modrdn.c index 8bf032189e..7c8b4390bf 100644 --- a/servers/slapd/modrdn.c +++ b/servers/slapd/modrdn.c @@ -401,6 +401,9 @@ slap_modrdn2mods( Modifications *mod = NULL; int a_cnt, d_cnt; + assert( new_rdn != NULL ); + assert( !deleteoldrdn || old_rdn != NULL ); + /* Add new attribute values to the entry */ for ( a_cnt = 0; new_rdn[ 0 ][ a_cnt ]; a_cnt++ ) { AttributeDescription *desc = NULL;