diff options
Diffstat (limited to 'source3/passdb')
-rw-r--r-- | source3/passdb/pampass.c | 6 | ||||
-rw-r--r-- | source3/passdb/pdb_smbpasswd.c | 6 |
2 files changed, 4 insertions, 8 deletions
diff --git a/source3/passdb/pampass.c b/source3/passdb/pampass.c index 271c46045b..d9137045e2 100644 --- a/source3/passdb/pampass.c +++ b/source3/passdb/pampass.c @@ -337,12 +337,12 @@ static BOOL proc_pam_session(pam_handle_t *pamh, char *user, char *tty, BOOL fla /* * PAM Externally accessible Session handler */ -BOOL pam_session(BOOL flag, const connection_struct *conn, char *tty) +BOOL pam_session(BOOL flag, const char *in_user, char *tty) { pam_handle_t *pamh = NULL; char * user; - user = malloc(strlen(conn->user)+1); + user = malloc(strlen(in_user)+1); if ( user == NULL ) { DEBUG(0, ("PAM: PAM_session Malloc Failed!\n")); @@ -350,7 +350,7 @@ BOOL pam_session(BOOL flag, const connection_struct *conn, char *tty) } /* This is freed by PAM */ - StrnCpy(user, conn->user, strlen(conn->user)+1); + StrnCpy(user, in_user, strlen(in_user)+1); if (!proc_pam_start(&pamh, user)) { diff --git a/source3/passdb/pdb_smbpasswd.c b/source3/passdb/pdb_smbpasswd.c index 2449eec1f0..a814c8da8e 100644 --- a/source3/passdb/pdb_smbpasswd.c +++ b/source3/passdb/pdb_smbpasswd.c @@ -1285,11 +1285,7 @@ static BOOL build_sam_account (SAM_ACCOUNT *sam_pass, standard_sub_advanced(-1, pw_buf->smb_name, "", gid, str); pdb_set_homedir(sam_pass, str); - if (lp_unix_realname()) - pdb_set_fullname(sam_pass, pwfile->pw_gecos); - else - pdb_set_fullname(sam_pass, "<Full Name>"); - + pdb_set_fullname(sam_pass, pwfile->pw_gecos); /* set other user information that we have */ pdb_set_group_rid (sam_pass, pdb_gid_to_group_rid(pdb_get_gid(&global_sam_pass)) ); |