]> git.sur5r.net Git - openldap/commitdiff
ITS#5776 prevent duplicate removal of qtask from runqueue.
authorRein Tollevik <rein@openldap.org>
Tue, 28 Oct 2008 20:33:46 +0000 (20:33 +0000)
committerRein Tollevik <rein@openldap.org>
Tue, 28 Oct 2008 20:33:46 +0000 (20:33 +0000)
servers/slapd/overlays/syncprov.c

index db113f042be0ff142df37556fb467e8ef86027f3..7aaa5f9c67a7bfc3e2a8ea2f49507c078144bb03 100644 (file)
@@ -908,6 +908,10 @@ syncprov_qplay( Operation *op, struct re_s *rtask )
        } else {
                /* bail out on any error */
                ldap_pvt_runqueue_remove( &slapd_rq, rtask );
+
+               /* Prevent duplicate remove */
+               if ( so->s_qtask == rtask )
+                       so->s_qtask = NULL;
        }
        ldap_pvt_thread_mutex_unlock( &slapd_rq.rq_mutex );
        ldap_pvt_thread_mutex_unlock( &so->s_mutex );