Page Menu
Home
FreeBSD
Search
Configure Global Search
Log In
Files
F106948686
D43423.diff
No One
Temporary
Actions
View File
Edit File
Delete File
View Transforms
Subscribe
Mute Notifications
Flag For Later
Award Token
Size
518 B
Referenced Files
None
Subscribers
None
D43423.diff
View Options
diff --git a/usr.bin/login/login.c b/usr.bin/login/login.c
--- a/usr.bin/login/login.c
+++ b/usr.bin/login/login.c
@@ -704,8 +704,10 @@
pam_err = pam_get_item(pamh, PAM_USER, &item);
if (pam_err == PAM_SUCCESS) {
tmpl_user = (const char *)item;
- if (strcmp(username, tmpl_user) != 0)
- pwd = getpwnam(tmpl_user);
+ if (strcmp(username, tmpl_user) != 0) {
+ (void)getpwnam_r(tmpl_user, &pwres, pwbuf,
+ sizeof(pwbuf), &pwd);
+ }
} else {
pam_syslog("pam_get_item(PAM_USER)");
}
File Metadata
Details
Attached
Mime Type
text/plain
Expires
Wed, Jan 8, 10:29 PM (3 h, 47 m)
Storage Engine
blob
Storage Format
Raw Data
Storage Handle
15727057
Default Alt Text
D43423.diff (518 B)
Attached To
Mode
D43423: login: Missed an instance of getpwnam().
Attached
Detach File
Event Timeline
Log In to Comment