diff options
author | Eric Paris <eparis@redhat.com> | 2009-01-26 18:09:45 -0500 |
---|---|---|
committer | Al Viro <viro@zeniv.linux.org.uk> | 2009-04-05 13:48:52 -0400 |
commit | 679173b724631f49e537a15fa48ea2000bdc1808 (patch) | |
tree | f5211fea378788dab49654e15916f6ba73faa4b4 | |
parent | 318b6d3d7ddbcad3d6867e630711b8a705d873d7 (diff) | |
download | kernel_samsung_tuna-679173b724631f49e537a15fa48ea2000bdc1808.zip kernel_samsung_tuna-679173b724631f49e537a15fa48ea2000bdc1808.tar.gz kernel_samsung_tuna-679173b724631f49e537a15fa48ea2000bdc1808.tar.bz2 |
audit: audit_set_auditable defined but not used
after 0590b9335a1c72a3f0defcc6231287f7817e07c8 audit_set_auditable() is now only
used by the audit tree code. If CONFIG_AUDIT_TREE is unset it will be defined
but unused. This patch simply moves the function inside a CONFIG_AUDIT_TREE
block.
cc1: warnings being treated as errors
/home/acme_unencrypted/git/linux-2.6-tip/kernel/auditsc.c:745: error: ‘audit_set_auditable’ defined but not used
make[2]: *** [kernel/auditsc.o] Error 1
make[1]: *** [kernel] Error 2
make[1]: *** Waiting for unfinished jobs....
Signed-off-by: Eric Paris <eparis@redhat.com>
Signed-off-by: Al Viro <viro@zeniv.linux.org.uk>
-rw-r--r-- | kernel/auditsc.c | 16 |
1 files changed, 8 insertions, 8 deletions
diff --git a/kernel/auditsc.c b/kernel/auditsc.c index e821d62..aa0428e 100644 --- a/kernel/auditsc.c +++ b/kernel/auditsc.c @@ -329,6 +329,14 @@ static int audit_match_filetype(struct audit_context *ctx, int which) */ #ifdef CONFIG_AUDIT_TREE +static void audit_set_auditable(struct audit_context *ctx) +{ + if (!ctx->prio) { + ctx->prio = 1; + ctx->current_state = AUDIT_RECORD_CONTEXT; + } +} + static int put_tree_ref(struct audit_context *ctx, struct audit_chunk *chunk) { struct audit_tree_refs *p = ctx->trees; @@ -742,14 +750,6 @@ void audit_filter_inodes(struct task_struct *tsk, struct audit_context *ctx) rcu_read_unlock(); } -static void audit_set_auditable(struct audit_context *ctx) -{ - if (!ctx->prio) { - ctx->prio = 1; - ctx->current_state = AUDIT_RECORD_CONTEXT; - } -} - static inline struct audit_context *audit_get_context(struct task_struct *tsk, int return_valid, long return_code) |