From: Pierangelo Masarati Date: Fri, 6 May 2005 10:21:00 +0000 (+0000) Subject: add support for "subordinate" scope X-Git-Tag: OPENLDAP_AC_BP~715 X-Git-Url: https://git.sur5r.net/?a=commitdiff_plain;h=5ad7133202874dd09e0d30984677aedfbff33ecc;p=openldap add support for "subordinate" scope --- diff --git a/servers/slapd/back-meta/search.c b/servers/slapd/back-meta/search.c index 42e7cb993a..ae30ba1d9f 100644 --- a/servers/slapd/back-meta/search.c +++ b/servers/slapd/back-meta/search.c @@ -106,6 +106,9 @@ meta_back_search_start( } break; +#ifdef LDAP_SCOPE_SUBORDINATE + case LDAP_SCOPE_SUBORDINATE: +#endif /* LDAP_SCOPE_SUBORDINATE */ case LDAP_SCOPE_ONELEVEL: { struct berval rdn = mi->mi_targets[ candidate ].mt_nsuffix; @@ -119,7 +122,14 @@ meta_back_search_start( * base, and make scope "base" */ realbase = mi->mi_targets[ candidate ].mt_nsuffix; - realscope = LDAP_SCOPE_BASE; +#ifdef LDAP_SCOPE_SUBORDINATE + if ( op->ors_scope == LDAP_SCOPE_SUBORDINATE ) { + realscope = LDAP_SCOPE_SUBTREE; + } else +#endif /* LDAP_SCOPE_SUBORDINATE */ + { + realscope = LDAP_SCOPE_BASE; + } break; } /* else continue with the next case */ }