]> git.sur5r.net Git - openldap/commitdiff
ITS#5783 / 5795 fix undef_promote
authorHoward Chu <hyc@openldap.org>
Thu, 6 Nov 2008 16:27:01 +0000 (16:27 +0000)
committerHoward Chu <hyc@openldap.org>
Thu, 6 Nov 2008 16:27:01 +0000 (16:27 +0000)
servers/slapd/ad.c

index e17aecb9e897cf1a42eef9120c3ad7eb4fd35c57..b43df86ca6dd77341e7b643b7a1511e3449370a5 100644 (file)
@@ -817,7 +817,10 @@ undef_promote(
 
                        *u_ad = (*u_ad)->ad_next;
 
+                       tmp->ad_type = nat;
                        tmp->ad_next = NULL;
+                       /* ad_cname was contiguous, no leak here */
+                       tmp->ad_cname = nat->sat_cname;
                        *n_ad = tmp;
                        n_ad = &tmp->ad_next;
                } else {