From 1b91a3872c2bd45687687db0179fe202d15e1af3 Mon Sep 17 00:00:00 2001 From: Kurt Zeilenga Date: Mon, 3 Dec 2001 20:05:46 +0000 Subject: [PATCH] Add additional sanity check --- servers/slapd/modify.c | 5 ++++- 1 file changed, 4 insertions(+), 1 deletion(-) diff --git a/servers/slapd/modify.c b/servers/slapd/modify.c index 6264636007..783d9ac89f 100644 --- a/servers/slapd/modify.c +++ b/servers/slapd/modify.c @@ -555,7 +555,7 @@ int slap_mods_opattrs( mod->sml_bvalues = (struct berval **) malloc( 2 * sizeof( struct berval * ) ); mod->sml_bvalues[0] = ber_bvdup( &name ); mod->sml_bvalues[1] = NULL; - + assert( mod->sml_bvalues[0] ); *modtail = mod; modtail = &mod->sml_next; @@ -565,6 +565,7 @@ int slap_mods_opattrs( mod->sml_bvalues = (struct berval **) malloc( 2 * sizeof( struct berval * ) ); mod->sml_bvalues[0] = ber_bvdup( ×tamp ); mod->sml_bvalues[1] = NULL; + assert( mod->sml_bvalues[0] ); *modtail = mod; modtail = &mod->sml_next; } @@ -575,6 +576,7 @@ int slap_mods_opattrs( mod->sml_bvalues = (struct berval **) malloc( 2 * sizeof( struct berval * ) ); mod->sml_bvalues[0] = ber_bvdup( &name ); mod->sml_bvalues[1] = NULL; + assert( mod->sml_bvalues[0] ); *modtail = mod; modtail = &mod->sml_next; @@ -584,6 +586,7 @@ int slap_mods_opattrs( mod->sml_bvalues = (struct berval **) malloc( 2 * sizeof( struct berval * ) ); mod->sml_bvalues[0] = ber_bvdup( ×tamp ); mod->sml_bvalues[1] = NULL; + assert( mod->sml_bvalues[0] ); *modtail = mod; modtail = &mod->sml_next; -- 2.39.5