aboutsummaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
-rw-r--r--kernel/auditsc.c12
1 files changed, 6 insertions, 6 deletions
diff --git a/kernel/auditsc.c b/kernel/auditsc.c
index b408100dd6ef..d7382c2aaa9e 100644
--- a/kernel/auditsc.c
+++ b/kernel/auditsc.c
@@ -805,7 +805,7 @@ static inline struct audit_context *audit_get_context(struct task_struct *tsk,
805{ 805{
806 struct audit_context *context = tsk->audit_context; 806 struct audit_context *context = tsk->audit_context;
807 807
808 if (likely(!context)) 808 if (!context)
809 return NULL; 809 return NULL;
810 context->return_valid = return_valid; 810 context->return_valid = return_valid;
811 811
@@ -928,7 +928,7 @@ int audit_alloc(struct task_struct *tsk)
928 return 0; /* Return if not auditing. */ 928 return 0; /* Return if not auditing. */
929 929
930 state = audit_filter_task(tsk, &key); 930 state = audit_filter_task(tsk, &key);
931 if (likely(state == AUDIT_DISABLED)) 931 if (state == AUDIT_DISABLED)
932 return 0; 932 return 0;
933 933
934 if (!(context = audit_alloc_context(state))) { 934 if (!(context = audit_alloc_context(state))) {
@@ -1599,7 +1599,7 @@ void audit_free(struct task_struct *tsk)
1599 struct audit_context *context; 1599 struct audit_context *context;
1600 1600
1601 context = audit_get_context(tsk, 0, 0); 1601 context = audit_get_context(tsk, 0, 0);
1602 if (likely(!context)) 1602 if (!context)
1603 return; 1603 return;
1604 1604
1605 /* Check for system calls that do not go through the exit 1605 /* Check for system calls that do not go through the exit
@@ -1640,7 +1640,7 @@ void __audit_syscall_entry(int arch, int major,
1640 struct audit_context *context = tsk->audit_context; 1640 struct audit_context *context = tsk->audit_context;
1641 enum audit_state state; 1641 enum audit_state state;
1642 1642
1643 if (unlikely(!context)) 1643 if (!context)
1644 return; 1644 return;
1645 1645
1646 /* 1646 /*
@@ -1697,7 +1697,7 @@ void __audit_syscall_entry(int arch, int major,
1697 context->prio = 0; 1697 context->prio = 0;
1698 state = audit_filter_syscall(tsk, context, &audit_filter_list[AUDIT_FILTER_ENTRY]); 1698 state = audit_filter_syscall(tsk, context, &audit_filter_list[AUDIT_FILTER_ENTRY]);
1699 } 1699 }
1700 if (likely(state == AUDIT_DISABLED)) 1700 if (state == AUDIT_DISABLED)
1701 return; 1701 return;
1702 1702
1703 context->serial = 0; 1703 context->serial = 0;
@@ -1748,7 +1748,7 @@ void __audit_syscall_exit(int success, long return_code)
1748 success = AUDITSC_FAILURE; 1748 success = AUDITSC_FAILURE;
1749 1749
1750 context = audit_get_context(tsk, success, return_code); 1750 context = audit_get_context(tsk, success, return_code);
1751 if (likely(!context)) 1751 if (!context)
1752 return; 1752 return;
1753 1753
1754 if (context->in_syscall && context->current_state == AUDIT_RECORD_CONTEXT) 1754 if (context->in_syscall && context->current_state == AUDIT_RECORD_CONTEXT)