diff options
author | Volker Lendecke <vl@samba.org> | 2010-02-28 14:38:14 +0100 |
---|---|---|
committer | Volker Lendecke <vl@samba.org> | 2010-02-28 14:40:25 +0100 |
commit | 0e9882a65e91e4ab55dc103c7f6aec4ccd966db0 (patch) | |
tree | 359061dade372995cf2496b464479387d826e7c5 /source3/winbindd/wb_next_pwent.c | |
parent | 99fc004e409ba5e535f1662e92370952777e55ff (diff) | |
download | samba-0e9882a65e91e4ab55dc103c7f6aec4ccd966db0.tar.gz |
s3: Fix but 7145 -- duplicate sam and unix accounts
For me this survives the
TESTS=posix_s3 POSIX_SUBTESTS="RPC-SAMR-LARGE-DC LOCAL-NSS-WRAPPER" make test
reproducer. Günther, please check!
Volker
Diffstat (limited to 'source3/winbindd/wb_next_pwent.c')
-rw-r--r-- | source3/winbindd/wb_next_pwent.c | 11 |
1 files changed, 11 insertions, 0 deletions
diff --git a/source3/winbindd/wb_next_pwent.c b/source3/winbindd/wb_next_pwent.c index 25ab7b38d3a..fbaaa48b6b8 100644 --- a/source3/winbindd/wb_next_pwent.c +++ b/source3/winbindd/wb_next_pwent.c @@ -55,6 +55,11 @@ struct tevent_req *wb_next_pwent_send(TALLOC_CTX *mem_ctx, state->gstate->domain = state->gstate->domain->next; } + if ((state->gstate->domain != NULL) + && sid_check_is_domain(&state->gstate->domain->sid)) { + state->gstate->domain = state->gstate->domain->next; + } + if (state->gstate->domain == NULL) { tevent_req_nterror(req, NT_STATUS_NO_MORE_ENTRIES); return tevent_req_post(req, ev); @@ -101,6 +106,12 @@ static void wb_next_pwent_fetch_done(struct tevent_req *subreq) if (state->gstate->num_users == 0) { state->gstate->domain = state->gstate->domain->next; + + if ((state->gstate->domain != NULL) + && sid_check_is_domain(&state->gstate->domain->sid)) { + state->gstate->domain = state->gstate->domain->next; + } + if (state->gstate->domain == NULL) { tevent_req_nterror(req, NT_STATUS_NO_MORE_ENTRIES); return; |