[Date Prev][Date Next] [Chronological] [Thread] [Top]

(ITS#3720) back meta sizelimit exceeded



Full_Name: Martin Evans
Version: 2.2.23
OS: Solaris 8
URL: 
Submission from: (NULL) (138.37.8.140)


There's some strange looking logic in back_meta/search.c I think it is
incorrectly reporting size limit exceeded for some searches. e.g. if you do
ldapsearch -z1 with a filter to return only 1 entry from a proxied tree.

Heres a patch, which fixes a short term problem that I have. is it reasonable?

--- search.c.0  2005-01-20 17:01:14.000000000 +0000
+++ search.c    2005-05-12 11:13:33.339285917 +0100
@@ -316,7 +316,7 @@
                        }

                        if ( op->ors_slimit > 0
-                                       && rs->sr_nentries == op->ors_slimit )
{
+                                       && rs->sr_nentries > op->ors_slimit ) {
                                rs->sr_err = LDAP_SIZELIMIT_EXCEEDED;
                                rs->sr_v2ref = v2refs;
                                send_ldap_result( op, rs );


And some obscured log messages for a search which returns only 1 entry and for a
client that has requested a sizelimit of 1:

May 12 09:16:10 epsilon slapd[13028]: [ID 998954 local4.debug] conn=153711 op=3
SRCH base="<our base dn>" scope=2 deref=0 filter="(uid=<a username>)"

May 12 09:16:12 epsilon slapd[13028]: [ID 362707 local4.debug] conn=153711 op=3
SEARCH RESULT tag=101 err=4 nentries=1 text=


Cheers,
Martin.