]> git.sur5r.net Git - openldap/commitdiff
Don't return useless estimate.
authorKurt Zeilenga <kurt@openldap.org>
Fri, 18 Jun 2004 23:07:56 +0000 (23:07 +0000)
committerKurt Zeilenga <kurt@openldap.org>
Fri, 18 Jun 2004 23:07:56 +0000 (23:07 +0000)
servers/slapd/back-bdb/search.c

index 2737d1fb826d1e29e3bf0bb0e341fe779a1e9316..2da62c485a56f9a6d2334b8d1e79b1e6df1969cd 100644 (file)
@@ -1713,8 +1713,8 @@ send_paged_response(
        LDAPControl     ctrl, *ctrls[2];
        BerElementBuffer berbuf;
        BerElement      *ber = (BerElement *)&berbuf;
-       struct berval   cookie = BER_BVC( "" );
        PagedResultsCookie respcookie;
+       struct berval cookie;
 
 #ifdef NEW_LOGGING
        LDAP_LOG ( OPERATION, ENTRY,
@@ -1739,17 +1739,16 @@ send_paged_response(
 
        } else {
                respcookie = ( PagedResultsCookie )0;
+               cookie.bv_val = "";
+               cookie.bv_len = 0;
        }
 
        op->o_conn->c_pagedresults_state.ps_cookie = respcookie;
        op->o_conn->c_pagedresults_state.ps_count =
                op->o_pagedresults_state.ps_count + rs->sr_nentries;
 
-       /*
-        * FIXME: we should consider sending an estimate of the entries
-        * left, after appropriate security check is done
-        */
-       ber_printf( ber, "{iO}", tentries, &cookie ); 
+       /* return size of 0 -- no estimate */
+       ber_printf( ber, "{iO}", 0, &cookie ); 
 
        if ( ber_flatten2( ber, &ctrls[0]->ldctl_value, 0 ) == -1 ) {
                goto done;