mirror of
https://github.com/samba-team/samba.git
synced 2025-01-17 02:05:21 +03:00
One less user of Get_Pwnam_modify()...
Andrew Bartlett (This used to be commit 06b8a6fef466e006724bc49165fe936cf8fcfbfa)
This commit is contained in:
parent
69b9cbf327
commit
e4eed6e8f4
@ -224,9 +224,11 @@ add a name to the session users list
|
||||
void add_session_user(const char *user)
|
||||
{
|
||||
fstring suser;
|
||||
StrnCpy(suser,user,sizeof(suser)-1);
|
||||
struct passwd *passwd;
|
||||
|
||||
if (!Get_Pwnam_Modify(suser)) return;
|
||||
if (!passwd = Get_Pwnam(user)) return;
|
||||
|
||||
StrnCpy(suser,passwd->pw_name,sizeof(suser)-1);
|
||||
|
||||
if (suser && *suser && !in_list(suser,session_users,False))
|
||||
{
|
||||
|
Loading…
x
Reference in New Issue
Block a user