audi: replace open-coded TDP_AUDITREC checks with the macro
Sponsored by: The FreeBSD Foundation
This commit is contained in:
parent
b6da2600f9
commit
e8451da5e8
Notes:
svn2git
2020-12-20 02:59:44 +00:00
svn path=/head/; revision=341822
@ -389,7 +389,7 @@ void audit_thread_free(struct thread *td);
|
|||||||
* auditing is disabled, so we don't just check audit_syscalls_enabled here.
|
* auditing is disabled, so we don't just check audit_syscalls_enabled here.
|
||||||
*/
|
*/
|
||||||
#define AUDIT_SYSCALL_EXIT(error, td) do { \
|
#define AUDIT_SYSCALL_EXIT(error, td) do { \
|
||||||
if (td->td_pflags & TDP_AUDITREC) \
|
if (AUDITING_TD(td)) \
|
||||||
audit_syscall_exit(error, td); \
|
audit_syscall_exit(error, td); \
|
||||||
} while (0)
|
} while (0)
|
||||||
|
|
||||||
@ -397,7 +397,7 @@ void audit_thread_free(struct thread *td);
|
|||||||
* A Macro to wrap the audit_sysclose() function.
|
* A Macro to wrap the audit_sysclose() function.
|
||||||
*/
|
*/
|
||||||
#define AUDIT_SYSCLOSE(td, fd) do { \
|
#define AUDIT_SYSCLOSE(td, fd) do { \
|
||||||
if (td->td_pflags & TDP_AUDITREC) \
|
if (AUDITING_TD(td)) \
|
||||||
audit_sysclose(td, fd); \
|
audit_sysclose(td, fd); \
|
||||||
} while (0)
|
} while (0)
|
||||||
|
|
||||||
|
Loading…
Reference in New Issue
Block a user