diff options
author | Tomas Mraz <tmraz@fedoraproject.org> | 2014-08-13 14:45:05 +0200 |
---|---|---|
committer | Tomas Mraz <tmraz@fedoraproject.org> | 2014-08-13 14:45:05 +0200 |
commit | 8f7f6da06091153702f38e283d8f34778ccf9eb2 (patch) | |
tree | 823b82f64f5230c5aa232c36fcf653d1f74f5c91 /modules/pam_access/pam_access.c | |
parent | 8731716646adc8065b45dc59b5e9ca1893d5a495 (diff) | |
download | pam-8f7f6da06091153702f38e283d8f34778ccf9eb2.tar.gz pam-8f7f6da06091153702f38e283d8f34778ccf9eb2.tar.bz2 pam-8f7f6da06091153702f38e283d8f34778ccf9eb2.zip |
pam_access: Avoid uninitialized access of line.
* modules/pam_access/pam_access.c (login_access): Reorder condition
so line is not accessed when uninitialized.
Diffstat (limited to 'modules/pam_access/pam_access.c')
-rw-r--r-- | modules/pam_access/pam_access.c | 4 |
1 files changed, 2 insertions, 2 deletions
diff --git a/modules/pam_access/pam_access.c b/modules/pam_access/pam_access.c index 87626e73..b32a966b 100644 --- a/modules/pam_access/pam_access.c +++ b/modules/pam_access/pam_access.c @@ -412,8 +412,8 @@ login_access (pam_handle_t *pamh, struct login_info *item) return NO; } #ifdef HAVE_LIBAUDIT - if (!item->noaudit && line[0] == '-' && (match == YES || (match == ALL && - nonall_match == YES))) { + if (!item->noaudit && (match == YES || (match == ALL && + nonall_match == YES)) && line[0] == '-') { pam_modutil_audit_write(pamh, AUDIT_ANOM_LOGIN_LOCATION, "pam_access", 0); } |