summaryrefslogtreecommitdiff
path: root/source3/lib/util_sid.c
diff options
context:
space:
mode:
authorJim McDonough <jmcd@samba.org>2004-04-06 22:02:47 +0000
committerGerald (Jerry) Carter <jerry@samba.org>2007-10-10 10:51:08 -0500
commitddc0716fa88bcef0dfe2396ad4b93a5904629d71 (patch)
treef1fe9807c08a56c4bad1ada0a69ccecde84f6f7a /source3/lib/util_sid.c
parentd2b58ab66f049fa33130673253ceca68774efdec (diff)
downloadsamba-ddc0716fa88bcef0dfe2396ad4b93a5904629d71.tar.gz
samba-ddc0716fa88bcef0dfe2396ad4b93a5904629d71.tar.bz2
samba-ddc0716fa88bcef0dfe2396ad4b93a5904629d71.zip
r91: Fix lsalookupnames. Previously we'd fail if we didn't find the name, but
we never checked if it was a domain user and didn't find a local one. (This used to be commit 68022f5ebc55d1f3403dee5198d364cff300baf5)
Diffstat (limited to 'source3/lib/util_sid.c')
-rw-r--r--source3/lib/util_sid.c7
1 files changed, 7 insertions, 0 deletions
diff --git a/source3/lib/util_sid.c b/source3/lib/util_sid.c
index 50bbb4c72c..e317f8f84e 100644
--- a/source3/lib/util_sid.c
+++ b/source3/lib/util_sid.c
@@ -201,6 +201,13 @@ void split_domain_name(const char *fullname, char *domain, char *name)
fstrcpy(domain, full_name);
fstrcpy(name, p+1);
} else {
+ if(!lp_domain_logons()) {
+ fstrcpy(domain, global_myname());
+ fstrcpy(name, full_name);
+ } else {
+ fstrcpy(domain, lp_workgroup());
+ fstrcpy(name, full_name);
+ }
fstrcpy(domain, global_myname());
fstrcpy(name, full_name);
}