From: Pierangelo Masarati Date: Wed, 20 Jun 2007 23:44:43 +0000 (+0000) Subject: fix potential NULL dereferencing (detected by Coverity) X-Git-Tag: OPENLDAP_REL_ENG_2_4_MP~367 X-Git-Url: https://git.sur5r.net/?a=commitdiff_plain;h=35282bc713e7f6b84a989f13315e63c404410424;p=openldap fix potential NULL dereferencing (detected by Coverity) --- diff --git a/servers/slapd/syntax.c b/servers/slapd/syntax.c index a2c201a2e8..b9fb273fe2 100644 --- a/servers/slapd/syntax.c +++ b/servers/slapd/syntax.c @@ -194,7 +194,7 @@ syn_add( for ( cnt = 0; def->sd_sups[cnt] != NULL; cnt++ ) ; - ssyn->ssyn_sups = (Syntax **)SLAP_CALLOC( cnt + 1, + ssyn->ssyn_sups = (Syntax **)ch_calloc( cnt + 1, sizeof(Syntax) ); for ( cnt = 0; def->sd_sups[cnt] != NULL; cnt++ ) {