diff options
author | Stef <stef@ws.local> | 2004-06-08 19:24:58 +0000 |
---|---|---|
committer | Stef <stef@ws.local> | 2004-06-08 19:24:58 +0000 |
commit | 719790c0a8351ce519827419dbf7e1a2a774fae4 (patch) | |
tree | f9eaa854bcb5700a070d269b133476633af8a94f /src/com/memberwebs | |
parent | f2b3b94f01314b0721906c494e6ae793fe500e21 (diff) |
Fixed bug where too many entries were read for a depth of 1 and 0
Diffstat (limited to 'src/com/memberwebs')
-rw-r--r-- | src/com/memberwebs/ldapxml/LXReader.java | 13 |
1 files changed, 12 insertions, 1 deletions
diff --git a/src/com/memberwebs/ldapxml/LXReader.java b/src/com/memberwebs/ldapxml/LXReader.java index 420925a..50fa0a2 100644 --- a/src/com/memberwebs/ldapxml/LXReader.java +++ b/src/com/memberwebs/ldapxml/LXReader.java @@ -207,8 +207,19 @@ public class LXReader if(sort == null) cons.setMaxResults(last + 1); + int scope = LDAPConnection.SCOPE_SUB; + switch(specs.getDepth()) + { + case 0: + scope = LDAPConnection.SCOPE_BASE; + break; + case 1: + scope = LDAPConnection.SCOPE_ONE; + break; + } + // Search tree for entries - LDAPSearchResults results = m_connection.search(base, LDAPConnection.SCOPE_SUB, + LDAPSearchResults results = m_connection.search(base, scope, specs.getFilter(filter), attrs, false, cons); if(sort != null) |