diff options
author | jmallett <jmallett@FreeBSD.org> | 2002-05-22 23:18:25 +0000 |
---|---|---|
committer | jmallett <jmallett@FreeBSD.org> | 2002-05-22 23:18:25 +0000 |
commit | f49de037592adf9327e7645dd13996bd0ea7d842 (patch) | |
tree | 379fdfbeb6ff1ee976d2edc129a10734eefa3f11 /lib | |
parent | 981165838bba6b8b763d0ed78bf28694b78ab006 (diff) | |
download | FreeBSD-src-f49de037592adf9327e7645dd13996bd0ea7d842.zip FreeBSD-src-f49de037592adf9327e7645dd13996bd0ea7d842.tar.gz |
Free old_pwd only in the code path where it has been allocated.
Reviewed by: des
Diffstat (limited to 'lib')
-rw-r--r-- | lib/libpam/modules/pam_unix/pam_unix.c | 2 |
1 files changed, 1 insertions, 1 deletions
diff --git a/lib/libpam/modules/pam_unix/pam_unix.c b/lib/libpam/modules/pam_unix/pam_unix.c index dfd7b99..de7dcc8 100644 --- a/lib/libpam/modules/pam_unix/pam_unix.c +++ b/lib/libpam/modules/pam_unix/pam_unix.c @@ -420,6 +420,7 @@ pam_sm_chauthtok(pam_handle_t *pamh, int flags, retval = PAM_SERVICE_ERR; } #endif + free(old_pwd); } else { /* Very bad juju */ @@ -427,7 +428,6 @@ pam_sm_chauthtok(pam_handle_t *pamh, int flags, PAM_LOG("Illegal 'flags'"); } - free(old_pwd); return (retval); } |