mirror of
https://git.FreeBSD.org/src.git
synced 2025-01-17 15:27:36 +00:00
Restore the NULL check that was removed in upstream r913. It is not
unreasonable to call pam_end() with a NULL pamh in error handling code. Reported by: rwatson
This commit is contained in:
parent
7e31684ea4
commit
e4deb071bd
Notes:
svn2git
2020-12-20 02:59:44 +00:00
svn path=/head/; revision=315909
@ -72,8 +72,7 @@ pam_close_session(pam_handle_t *_pamh,
|
||||
|
||||
int
|
||||
pam_end(pam_handle_t *_pamh,
|
||||
int _status)
|
||||
OPENPAM_NONNULL((1));
|
||||
int _status);
|
||||
|
||||
int
|
||||
pam_get_data(const pam_handle_t *_pamh,
|
||||
|
@ -60,6 +60,8 @@ pam_end(pam_handle_t *pamh,
|
||||
int i;
|
||||
|
||||
ENTER();
|
||||
if (pamh == NULL)
|
||||
RETURNC(PAM_SYSTEM_ERR);
|
||||
|
||||
/* clear module data */
|
||||
while ((dp = pamh->module_data) != NULL) {
|
||||
|
Loading…
Reference in New Issue
Block a user