summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
-rw-r--r--source3/nsswitch/winbindd_user.c6
1 files changed, 6 insertions, 0 deletions
diff --git a/source3/nsswitch/winbindd_user.c b/source3/nsswitch/winbindd_user.c
index 198c54c039..fac2832f56 100644
--- a/source3/nsswitch/winbindd_user.c
+++ b/source3/nsswitch/winbindd_user.c
@@ -245,6 +245,12 @@ static void getpwsid_queryuser_recv(void *private_data, BOOL success,
struct winbindd_domain *domain = NULL;
domain = find_lookup_domain_from_sid(&s->user_sid);
+ if (domain == NULL) {
+ DEBUG(5, ("find_lookup_domain_from_sid(%s) failed\n",
+ sid_string_static(&s->user_sid)));
+ request_error(s->state);
+ return;
+ }
winbindd_lookup_name_by_sid(s->state->mem_ctx, domain,
&s->user_sid, &domain_name,
&user_name, &type );