summaryrefslogtreecommitdiff
path: root/source3
diff options
context:
space:
mode:
authorAndrew Bartlett <abartlet@samba.org>2003-02-20 10:43:21 +0000
committerAndrew Bartlett <abartlet@samba.org>2003-02-20 10:43:21 +0000
commit215ff67a039d3dea516d70d538083db8833f7b7e (patch)
tree0d134c606ba0b7a37881c5582006e344aec4a496 /source3
parentf8d9cf27266d9ce563011e44281483a4dfd0708f (diff)
downloadsamba-215ff67a039d3dea516d70d538083db8833f7b7e.tar.gz
samba-215ff67a039d3dea516d70d538083db8833f7b7e.tar.bz2
samba-215ff67a039d3dea516d70d538083db8833f7b7e.zip
for some (very weird) reason, the domain I was testing aginst would not
return a DN for the user. Make sure we don't segfault. Andrew Bartlett (This used to be commit 9fdedeff6a3a9f8e8d048e6afd7001ad676c4e91)
Diffstat (limited to 'source3')
-rw-r--r--source3/nsswitch/winbindd_ads.c4
1 files changed, 4 insertions, 0 deletions
diff --git a/source3/nsswitch/winbindd_ads.c b/source3/nsswitch/winbindd_ads.c
index be4ed1c667..9560a53fa0 100644
--- a/source3/nsswitch/winbindd_ads.c
+++ b/source3/nsswitch/winbindd_ads.c
@@ -490,6 +490,10 @@ static NTSTATUS lookup_usergroups(struct winbindd_domain *domain,
}
user_dn = ads_pull_string(ads, mem_ctx, msg, "distinguishedName");
+ if (!user_dn) {
+ DEBUG(1,("lookup_usergroups(rid=%d) ads_search did not return a a distinguishedName!\n", user_rid));
+ goto done;
+ }
if (msg) ads_msgfree(ads, msg);