diff options
Diffstat (limited to 'include/linux')
| -rw-r--r-- | include/linux/audit.h | 7 |
1 files changed, 6 insertions, 1 deletions
diff --git a/include/linux/audit.h b/include/linux/audit.h index 4f1efe3e8616..8eb8bda749b3 100644 --- a/include/linux/audit.h +++ b/include/linux/audit.h | |||
| @@ -417,7 +417,7 @@ extern int audit_classify_arch(int arch); | |||
| 417 | /* Public API */ | 417 | /* Public API */ |
| 418 | extern void audit_finish_fork(struct task_struct *child); | 418 | extern void audit_finish_fork(struct task_struct *child); |
| 419 | extern int audit_alloc(struct task_struct *task); | 419 | extern int audit_alloc(struct task_struct *task); |
| 420 | extern void audit_free(struct task_struct *task); | 420 | extern void __audit_free(struct task_struct *task); |
| 421 | extern void __audit_syscall_entry(int arch, | 421 | extern void __audit_syscall_entry(int arch, |
| 422 | int major, unsigned long a0, unsigned long a1, | 422 | int major, unsigned long a0, unsigned long a1, |
| 423 | unsigned long a2, unsigned long a3); | 423 | unsigned long a2, unsigned long a3); |
| @@ -435,6 +435,11 @@ static inline int audit_dummy_context(void) | |||
| 435 | void *p = current->audit_context; | 435 | void *p = current->audit_context; |
| 436 | return !p || *(int *)p; | 436 | return !p || *(int *)p; |
| 437 | } | 437 | } |
| 438 | static inline void audit_free(struct task_struct *task) | ||
| 439 | { | ||
| 440 | if (unlikely(task->audit_context)) | ||
| 441 | __audit_free(task); | ||
| 442 | } | ||
| 438 | static inline void audit_syscall_entry(int arch, int major, unsigned long a0, | 443 | static inline void audit_syscall_entry(int arch, int major, unsigned long a0, |
| 439 | unsigned long a1, unsigned long a2, | 444 | unsigned long a1, unsigned long a2, |
| 440 | unsigned long a3) | 445 | unsigned long a3) |
