From: Pierangelo Masarati Date: Mon, 9 Apr 2012 22:46:06 +0000 (+0200) Subject: ITS#7224 check *_names pointer before dereferencing X-Git-Url: https://git.sur5r.net/?a=commitdiff_plain;h=d7d1789e8077d97077abe9d0ee4f397d3f390a3f;p=openldap ITS#7224 check *_names pointer before dereferencing --- diff --git a/servers/slapd/at.c b/servers/slapd/at.c index e4d95541e2..0ae958094b 100644 --- a/servers/slapd/at.c +++ b/servers/slapd/at.c @@ -232,6 +232,8 @@ at_delete_names( AttributeType *at ) { char **names = at->sat_names; + if (!names) return; + while (*names) { struct aindexrec tmpair, *air; diff --git a/servers/slapd/oc.c b/servers/slapd/oc.c index df56e4d22f..2dbe6fc285 100644 --- a/servers/slapd/oc.c +++ b/servers/slapd/oc.c @@ -400,6 +400,8 @@ oc_delete_names( ObjectClass *oc ) { char **names = oc->soc_names; + if (!names) return; + while (*names) { struct oindexrec tmpoir, *oir;