diff options
author | Thorsten Kukuk <kukuk@thkukuk.de> | 2005-07-26 06:40:44 +0000 |
---|---|---|
committer | Thorsten Kukuk <kukuk@thkukuk.de> | 2005-07-26 06:40:44 +0000 |
commit | 36c62d04e3ba798dbfcf01a7892f31d5fe1a8646 (patch) | |
tree | 863e1544bd0f51c8533857dc6295a07df072e360 /modules/pam_unix/pam_unix_auth.c | |
parent | db615c19519745fcff13d3fc8b27c582130bb464 (diff) | |
download | pam-36c62d04e3ba798dbfcf01a7892f31d5fe1a8646.tar.gz pam-36c62d04e3ba798dbfcf01a7892f31d5fe1a8646.tar.bz2 pam-36c62d04e3ba798dbfcf01a7892f31d5fe1a8646.zip |
Relevant BUGIDs: mailing list
Purpose of commit: bugfix
Commit summary:
---------------
Don't ignore return values of pam_get_item
Diffstat (limited to 'modules/pam_unix/pam_unix_auth.c')
-rw-r--r-- | modules/pam_unix/pam_unix_auth.c | 4 |
1 files changed, 2 insertions, 2 deletions
diff --git a/modules/pam_unix/pam_unix_auth.c b/modules/pam_unix/pam_unix_auth.c index 23eba7e6..38e78152 100644 --- a/modules/pam_unix/pam_unix_auth.c +++ b/modules/pam_unix/pam_unix_auth.c @@ -207,8 +207,8 @@ PAM_EXTERN int pam_sm_setcred(pam_handle_t * pamh, int flags D(("recovering return code from auth call")); /* We will only find something here if UNIX_LIKE_AUTH is set -- don't worry about an explicit check of argv. */ - pam_get_data(pamh, "unix_setcred_return", &pretval); - if(pretval) { + if (pam_get_data(pamh, "unix_setcred_return", &pretval) == PAM_SUCCESS + && pretval) { retval = *(const int *)pretval; pam_set_data(pamh, "unix_setcred_return", NULL, NULL); D(("recovered data indicates that old retval was %d", retval)); |