]> git.sur5r.net Git - openldap/commitdiff
Really fix those reader/writer lock asserts...
authorKurt Zeilenga <kurt@openldap.org>
Sun, 7 Feb 1999 17:57:50 +0000 (17:57 +0000)
committerKurt Zeilenga <kurt@openldap.org>
Sun, 7 Feb 1999 17:57:50 +0000 (17:57 +0000)
servers/slapd/back-ldbm/cache.c

index 8d3e84d7e913a99e84c8bd15fc56aa6a19244abe..46d8c655b612581aee8f4e98116a74474d8d51ed 100644 (file)
@@ -213,9 +213,9 @@ cache_add_entry_lock(
                     == 0 && cache->c_cursize > cache->c_maxsize ) {
                        e = cache->c_lrutail;
 
-                       /* XXX check for writer lock - should also check no readers pending */
+                       /* check for active readers/writer lock */
 #ifdef LDAP_DEBUG
-                       assert(ldap_pvt_thread_rdwr_writers( &e->e_rdwr ) == 1);
+                       assert(!ldap_pvt_thread_rdwr_active( &e->e_rdwr ));
 #endif
 
                        /* delete from cache and lru q */