summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorRalph Boehme <slow@samba.org>2019-02-21 16:52:21 +0100
committerKarolin Seeger <kseeger@samba.org>2019-03-05 07:39:28 +0000
commit447b0ad3a956909d72ce9de6cfa60f34ae23b437 (patch)
tree01092b998108d77d4965ca674380bf393085ff9d
parent19d06f27688b0931624911d15d26dbabaa39deb1 (diff)
downloadsamba-447b0ad3a956909d72ce9de6cfa60f34ae23b437.tar.gz
winbindd: switch send-next/done order
In preparation of adding more logic to the done step. No change in behaviour. Bug: https://bugzilla.samba.org/show_bug.cgi?id=13802 Signed-off-by: Ralph Boehme <slow@samba.org> Reviewed-by: Volker Lendecke <vl@samba.org> (cherry picked from commit 8e9c2a1f6ceb06d695a6572701b96a3e3821ac42)
-rw-r--r--source3/winbindd/wb_xids2sids.c22
1 files changed, 13 insertions, 9 deletions
diff --git a/source3/winbindd/wb_xids2sids.c b/source3/winbindd/wb_xids2sids.c
index 6555d64f8e2..d769328a15e 100644
--- a/source3/winbindd/wb_xids2sids.c
+++ b/source3/winbindd/wb_xids2sids.c
@@ -546,18 +546,22 @@ static void wb_xids2sids_done(struct tevent_req *subreq)
state->dom_idx += 1;
- if (state->dom_idx >= num_domains) {
- tevent_req_done(req);
+ if (state->dom_idx < num_domains) {
+ subreq = wb_xids2sids_dom_send(state,
+ state->ev,
+ &dom_maps[state->dom_idx],
+ state->xids,
+ state->num_xids,
+ state->sids);
+ if (tevent_req_nomem(subreq, req)) {
+ return;
+ }
+ tevent_req_set_callback(subreq, wb_xids2sids_done, req);
return;
}
- subreq = wb_xids2sids_dom_send(
- state, state->ev, &dom_maps[state->dom_idx],
- state->xids, state->num_xids, state->sids);
- if (tevent_req_nomem(subreq, req)) {
- return;
- }
- tevent_req_set_callback(subreq, wb_xids2sids_done, req);
+ tevent_req_done(req);
+ return;
}
NTSTATUS wb_xids2sids_recv(struct tevent_req *req, TALLOC_CTX *mem_ctx,