diff options
Diffstat (limited to 'source3/passdb')
-rw-r--r-- | source3/passdb/passdb.c | 13 |
1 files changed, 8 insertions, 5 deletions
diff --git a/source3/passdb/passdb.c b/source3/passdb/passdb.c index 9b1bd3d211..7eecbfd2cd 100644 --- a/source3/passdb/passdb.c +++ b/source3/passdb/passdb.c @@ -525,14 +525,17 @@ BOOL local_lookup_sid(DOM_SID *sid, char *name, enum SID_NAME_USE *psid_name_use if(is_user) { if(rid == DOMAIN_USER_RID_ADMIN) { - pstring admin_users; - char *p = admin_users; + char **admin_list = lp_admin_users(-1); *psid_name_use = SID_NAME_USER; - if(!next_token(&p, name, NULL, sizeof(fstring))) + if (admin_list) { + char *p = *admin_list; + if(!next_token(&p, name, NULL, sizeof(fstring))) + fstrcpy(name, "Administrator"); + } else { fstrcpy(name, "Administrator"); + } } else if (rid == DOMAIN_USER_RID_GUEST) { - pstring guest_users; - char *p = guest_users; + char *p = lp_guestaccount(); *psid_name_use = SID_NAME_USER; if(!next_token(&p, name, NULL, sizeof(fstring))) fstrcpy(name, "Guest"); |