]> git.sur5r.net Git - openldap/commitdiff
Unlock new_cached_query->rwlock before destroying it.
authorHallvard Furuseth <hallvard@openldap.org>
Fri, 11 Feb 2011 11:43:18 +0000 (11:43 +0000)
committerHallvard Furuseth <hallvard@openldap.org>
Fri, 11 Feb 2011 11:43:18 +0000 (11:43 +0000)
Fixes rev 1.210 (new since last OpenLDAP release).

servers/slapd/overlays/pcache.c

index 6f96ced908f7f77366e144a5e5229888d1a20140..cb03e3ed80710a22bc1f36a99e6608bee6bf70f1 100644 (file)
@@ -1601,6 +1601,8 @@ add_query(
                templ->no_of_queries++;
        } else {
                ldap_pvt_thread_mutex_destroy(&new_cached_query->answerable_cnt_mutex);
+               if (wlock)
+                       ldap_pvt_thread_rdwr_wunlock(&new_cached_query->rwlock);
                ldap_pvt_thread_rdwr_destroy( &new_cached_query->rwlock );
                ch_free( new_cached_query );
                new_cached_query = find_filter( op, qbase->scopes[query->scope],