From e3309f060a67805e679fee55b1101b91991ea824 Mon Sep 17 00:00:00 2001 From: Tobias Stoeckmann Date: Mon, 15 Jan 2024 20:05:28 +0100 Subject: pam_unix: fix regressions The returned value stored in pwd from _unix_getpwnam is inserted into pam handler through pam_set_data. Do not manually free the value. Also check getline return value for != -1 instead of == -1. Fixes 8f2ca5919b26843ef774ef0aeb9bf261dec943a0 and 73d009e9ea8edafc18c7fe3650b25dd6bdce88c1. No release affected. Signed-off-by: Tobias Stoeckmann --- modules/pam_unix/pam_unix_passwd.c | 1 - 1 file changed, 1 deletion(-) (limited to 'modules/pam_unix/pam_unix_passwd.c') diff --git a/modules/pam_unix/pam_unix_passwd.c b/modules/pam_unix/pam_unix_passwd.c index 7c141c3b..fe3f566a 100644 --- a/modules/pam_unix/pam_unix_passwd.c +++ b/modules/pam_unix/pam_unix_passwd.c @@ -660,7 +660,6 @@ pam_sm_chauthtok(pam_handle_t *pamh, int flags, int argc, const char **argv) user); return PAM_USER_UNKNOWN; } - _pam_drop(pwd); /* * This is not an AUTH module! -- cgit v1.2.3