The Samba-Bugzilla – Attachment 7215 Details for
Bug 8678
Segfault if we try to enumerate users and the last user can't be mapped to an uid
Home
|
New
|
Browse
|
Search
|
[?]
|
Reports
|
Requests
|
Help
|
New Account
|
Log In
[x]
|
Forgot Password
Login:
[x]
[patch]
Patch
0001-s3-winbind-Fix-segfault-if-we-can-t-map-the-last-use.patch (text/plain), 1.70 KB, created by
Andreas Schneider
on 2011-12-23 15:24:10 UTC
(
hide
)
Description:
Patch
Filename:
MIME Type:
Creator:
Andreas Schneider
Created:
2011-12-23 15:24:10 UTC
Size:
1.70 KB
patch
obsolete
>From 203ec1a45b67a7e750e10bb467292c0d6c92b6d8 Mon Sep 17 00:00:00 2001 >From: Andreas Schneider <asn@cryptomilk.org> >Date: Fri, 23 Dec 2011 14:29:38 +0100 >Subject: [PATCH] s3-winbind: Fix segfault if we can't map the last user. > >This fixes bug #8678. > >The issue is caused by bug #8608. > >Signed-off-by: Andreas Schneider <asn@samba.org> >--- > source3/winbindd/wb_next_pwent.c | 27 +++++++++++++++++++++++++++ > 1 files changed, 27 insertions(+), 0 deletions(-) > >diff --git a/source3/winbindd/wb_next_pwent.c b/source3/winbindd/wb_next_pwent.c >index d47b2fc..9091e48 100644 >--- a/source3/winbindd/wb_next_pwent.c >+++ b/source3/winbindd/wb_next_pwent.c >@@ -155,6 +155,33 @@ static void wb_next_pwent_fill_done(struct tevent_req *subreq) > if (NT_STATUS_EQUAL(status, NT_STATUS_NONE_MAPPED)) { > state->gstate->next_user += 1; > >+ if (state->gstate->next_user >= state->gstate->num_users) { >+ TALLOC_FREE(state->gstate->users); >+ >+ if (state->gstate->domain == NULL) { >+ state->gstate->domain = domain_list(); >+ } else { >+ 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; >+ } >+ subreq = wb_query_user_list_send(state, state->ev, >+ state->gstate->domain); >+ if (tevent_req_nomem(subreq, req)) { >+ return; >+ } >+ tevent_req_set_callback(subreq, wb_next_pwent_fetch_done, req); >+ return; >+ } >+ > subreq = wb_fill_pwent_send(state, > state->ev, > &state->gstate->users[state->gstate->next_user], >-- >1.7.8 >
You cannot view the attachment while viewing its details because your browser does not support IFRAMEs.
View the attachment on a separate page
.
View Attachment As Raw
Actions:
View
Attachments on
bug 8678
:
7215
|
7221
|
7222