diff options
author | Günther Deschner <gd@samba.org> | 2006-10-16 14:29:14 +0000 |
---|---|---|
committer | Gerald (Jerry) Carter <jerry@samba.org> | 2007-10-10 12:15:29 -0500 |
commit | 258f7b50dc3a513d6ea956e2231aa43a57fa81c7 (patch) | |
tree | 22937a508955b835886a44f913030d98ab10e47e /source3/nsswitch | |
parent | 25cba8669d7d97796ee880c779cdb036e45202b4 (diff) | |
download | samba-258f7b50dc3a513d6ea956e2231aa43a57fa81c7.tar.gz samba-258f7b50dc3a513d6ea956e2231aa43a57fa81c7.tar.bz2 samba-258f7b50dc3a513d6ea956e2231aa43a57fa81c7.zip |
r19340: Wait longer then 10 seconds for a samr_query_groupmem lookup to succeed.
Guenther
(This used to be commit 37dd019e21cab2f0df314b0b741f79422fc10d1b)
Diffstat (limited to 'source3/nsswitch')
-rw-r--r-- | source3/nsswitch/winbindd_rpc.c | 9 |
1 files changed, 9 insertions, 0 deletions
diff --git a/source3/nsswitch/winbindd_rpc.c b/source3/nsswitch/winbindd_rpc.c index 06f0d2cb60..2e2b895352 100644 --- a/source3/nsswitch/winbindd_rpc.c +++ b/source3/nsswitch/winbindd_rpc.c @@ -615,6 +615,7 @@ static NTSTATUS lookup_groupmem(struct winbindd_domain *domain, unsigned int j; fstring sid_string; struct rpc_pipe_client *cli; + unsigned int orig_timeout; DEBUG(10,("rpc: lookup_groupmem %s sid=%s\n", domain->name, sid_to_string(sid_string, group_sid))); @@ -637,10 +638,18 @@ static NTSTATUS lookup_groupmem(struct winbindd_domain *domain, /* Step #1: Get a list of user rids that are the members of the group. */ + /* This call can take a long time - allow the server to time out. + 35 seconds should do it. */ + + orig_timeout = cli_set_timeout(cli->cli, 35000); + result = rpccli_samr_query_groupmem(cli, mem_ctx, &group_pol, num_names, &rid_mem, name_types); + /* And restore our original timeout. */ + cli_set_timeout(cli->cli, orig_timeout); + rpccli_samr_close(cli, mem_ctx, &group_pol); if (!NT_STATUS_IS_OK(result)) |