]> git.sur5r.net Git - openldap/commitdiff
import fix to ITS#4668
authorPierangelo Masarati <ando@openldap.org>
Sat, 9 Sep 2006 00:15:11 +0000 (00:15 +0000)
committerPierangelo Masarati <ando@openldap.org>
Sat, 9 Sep 2006 00:15:11 +0000 (00:15 +0000)
CHANGES
servers/slapd/back-monitor/search.c

diff --git a/CHANGES b/CHANGES
index 73a6a470738efb14da657c768bc0525c57236aec..6236db3d04aff5201caf6c68a5c3d12d8076bf78 100644 (file)
--- a/CHANGES
+++ b/CHANGES
@@ -2,6 +2,7 @@ OpenLDAP 2.3 Change Log
 
 OpenLDAP 2.3.28 Engineering
        Added ldapsearch bad filter pattern check (ITS#4647)
+       Fixed slapd-monitor locking with scope "subordinate" (ITS#4668)
 
 OpenLDAP 2.3.27 Release
        Fixed libldap dangling pointer issue (previous fix was broken) (ITS#4405)
index e71afa20b0567be706392d2deeaebeea3cfe0484..027a7774e82f30833ea68fd97e4b730b5318b627 100644 (file)
@@ -35,8 +35,7 @@ monitor_send_children(
        Operation       *op,
        SlapReply       *rs,
        Entry           *e_parent,
-       int             sub
-)
+       int             sub )
 {
        monitor_info_t  *mi = ( monitor_info_t * )op->o_bd->be_private;
        Entry                   *e,
@@ -234,7 +233,9 @@ monitor_back_search( Operation *op, SlapReply *rs )
                break;
 
        case LDAP_SCOPE_ONELEVEL:
-               rc = monitor_send_children( op, rs, e, 0 );
+       case LDAP_SCOPE_SUBORDINATE:
+               rc = monitor_send_children( op, rs, e,
+                       op->oq_search.rs_scope == LDAP_SCOPE_SUBORDINATE );
                break;
 
        case LDAP_SCOPE_SUBTREE:
@@ -249,6 +250,10 @@ monitor_back_search( Operation *op, SlapReply *rs )
 
                rc = monitor_send_children( op, rs, e, 1 );
                break;
+
+       default:
+               rc = LDAP_UNWILLING_TO_PERFORM;
+               monitor_cache_release( mi, e );
        }
 
        rs->sr_attrs = NULL;