]> git.sur5r.net Git - openldap/blobdiff - servers/slapd/syncrepl.c
Plug mutex/rwlock leaks (destroy them)
[openldap] / servers / slapd / syncrepl.c
index 9b9c73e107b3866e5fc1201f00a3381743f76173..b2f7cd3be65f1764f49c9b2220e6fe4a4cda56c6 100644 (file)
@@ -1415,6 +1415,11 @@ do_syncrepl(
                si->si_refreshDelete = 0;
                si->si_refreshPresent = 0;
 
+               if ( si->si_presentlist ) {
+                   avl_free( si->si_presentlist, ch_free );
+                   si->si_presentlist = NULL;
+               }
+
                /* use main DB when retrieving contextCSN */
                op->o_bd = si->si_wbe;
                op->o_dn = op->o_bd->be_rootdn;
@@ -2910,7 +2915,7 @@ syncrepl_add_glue_ancestors(
        Backend *be = op->o_bd;
        slap_callback cb = { NULL };
        Attribute       *a;
-       int     rc;
+       int     rc = LDAP_SUCCESS;
        int suffrdns;
        int i;
        struct berval dn = BER_BVNULL;
@@ -4592,9 +4597,10 @@ add_syncrepl(
                return 1;
        } else {
                Debug( LDAP_DEBUG_CONFIG,
-                       "Config: ** successfully added syncrepl \"%s\"\n",
+                       "Config: ** successfully added syncrepl %s \"%s\"\n",
+                       si->si_ridtxt,
                        BER_BVISNULL( &si->si_bindconf.sb_uri ) ?
-                       "(null)" : si->si_bindconf.sb_uri.bv_val, 0, 0 );
+                       "(null)" : si->si_bindconf.sb_uri.bv_val, 0 );
                if ( c->be->be_syncinfo ) {
                        syncinfo_t *sip;