From 8e141eeda53f251dc62e9d459e02ecb27a6c0061 Mon Sep 17 00:00:00 2001 From: Noriko Hosoi Date: Mar 01 2010 17:44:53 +0000 Subject: 555970 - missing read lock in the combination of cos and nsview https://bugzilla.redhat.com/show_bug.cgi?id=555970 Description: view read lock was missing in a view api called from COS. --- diff --git a/ldap/servers/plugins/views/views.c b/ldap/servers/plugins/views/views.c index 68e991f..a6646d8 100644 --- a/ldap/servers/plugins/views/views.c +++ b/ldap/servers/plugins/views/views.c @@ -306,6 +306,9 @@ static int _internal_api_views_entry_exists_general(char *view_dn, Slapi_Entry * * view filter - either match will do */ + /* Read lock the cache */ + views_read_lock(); + /* find the view */ view = views_cache_find_view(view_dn); if(0==view) @@ -348,6 +351,7 @@ static int _internal_api_views_entry_exists_general(char *view_dn, Slapi_Entry * } bail: + views_unlock(); return ret; }