summaryrefslogtreecommitdiff
path: root/source3/nsswitch
diff options
context:
space:
mode:
authorJeremy Allison <jra@samba.org>2003-01-29 20:15:35 +0000
committerJeremy Allison <jra@samba.org>2003-01-29 20:15:35 +0000
commitf8601187caac93c5b03b2a5c6f06c674291a0a17 (patch)
treeb7bc3f4c54051f8e8bf1be57b7dc7c2222d466c7 /source3/nsswitch
parentaed54afc2cfc468d29b65b2b503d975070515528 (diff)
downloadsamba-f8601187caac93c5b03b2a5c6f06c674291a0a17.tar.gz
samba-f8601187caac93c5b03b2a5c6f06c674291a0a17.tar.bz2
samba-f8601187caac93c5b03b2a5c6f06c674291a0a17.zip
Merge tpot's changes to request the correct sizes for user dispinfo
from HEAD. I had to do this for him as he was *so* tired, the poor chap, plus he has this bad leg, plus the dog ate his homework etc. etc. Jeremy. (This used to be commit 1e752b48a12cdcf2cb6343705be83f304e5ee2b6)
Diffstat (limited to 'source3/nsswitch')
-rw-r--r--source3/nsswitch/winbindd_rpc.c15
1 files changed, 10 insertions, 5 deletions
diff --git a/source3/nsswitch/winbindd_rpc.c b/source3/nsswitch/winbindd_rpc.c
index edeacdec6d..b260e55c86 100644
--- a/source3/nsswitch/winbindd_rpc.c
+++ b/source3/nsswitch/winbindd_rpc.c
@@ -39,7 +39,7 @@ static NTSTATUS query_user_list(struct winbindd_domain *domain,
POLICY_HND dom_pol;
BOOL got_dom_pol = False;
uint32 des_access = SEC_RIGHTS_MAXIMUM_ALLOWED;
- int i;
+ int i, loop_count = 0;
DEBUG(3,("rpc: query_user_list\n"));
@@ -65,7 +65,7 @@ static NTSTATUS query_user_list(struct winbindd_domain *domain,
do {
SAM_DISPINFO_CTR ctr;
SAM_DISPINFO_1 info1;
- uint32 count = 0, start=i;
+ uint32 count = 0, start=i, max_entries, max_size;
int j;
TALLOC_CTX *ctx2;
@@ -77,10 +77,15 @@ static NTSTATUS query_user_list(struct winbindd_domain *domain,
goto done;
}
+ get_query_dispinfo_params(
+ loop_count, &max_entries, &max_size);
+
/* Query display info level 1 */
- result = cli_samr_query_dispinfo(hnd->cli, ctx2,
- &dom_pol, &start, 1,
- &count, 0xFFFF, &ctr);
+ result = cli_samr_query_dispinfo(
+ hnd->cli, ctx2, &dom_pol, &start, 1, &count,
+ max_entries, max_size, &ctr);
+
+ loop_count++;
if (!NT_STATUS_IS_OK(result) &&
!NT_STATUS_EQUAL(result, STATUS_MORE_ENTRIES)) break;