]> git.sur5r.net Git - openldap/commitdiff
Fix modtail initialization in loop
authorHoward Chu <hyc@openldap.org>
Mon, 22 Nov 2004 02:11:15 +0000 (02:11 +0000)
committerHoward Chu <hyc@openldap.org>
Mon, 22 Nov 2004 02:11:15 +0000 (02:11 +0000)
servers/slapd/syncrepl.c

index cf11fa07e0019387e65c8bbb2f4d465a24c0b774..5d2fdcf40def0af98ccbf7a81d49d7f9d9b7d6ad 100644 (file)
@@ -1483,7 +1483,7 @@ syncrepl_del_nonpresent(
        Modifications *mlnext;
        Modifications *mod;
        Modifications *modlist = NULL;
-       Modifications **modtail = &modlist;
+       Modifications **modtail;
        AttributeName   an[2];
 
        struct berval pdn = BER_BVNULL;
@@ -1543,6 +1543,7 @@ syncrepl_del_nonpresent(
                        rc = op->o_bd->be_delete( op, &rs_delete );
 
                        if ( rs_delete.sr_err == LDAP_NOT_ALLOWED_ON_NONLEAF ) {
+                               modtail = &modlist;
                                mod = (Modifications *) ch_calloc( 1, sizeof( Modifications ));
                                mod->sml_op = LDAP_MOD_REPLACE;
                                mod->sml_desc = slap_schema.si_ad_objectClass;