summaryrefslogtreecommitdiffstats
path: root/security/apparmor/lsm.c
diff options
context:
space:
mode:
Diffstat (limited to 'security/apparmor/lsm.c')
-rw-r--r--security/apparmor/lsm.c18
1 files changed, 9 insertions, 9 deletions
diff --git a/security/apparmor/lsm.c b/security/apparmor/lsm.c
index 628c6a07df64..fda36f3e3820 100644
--- a/security/apparmor/lsm.c
+++ b/security/apparmor/lsm.c
@@ -582,15 +582,15 @@ static int apparmor_getprocattr(struct task_struct *task, char *name,
int error = -ENOENT;
/* released below */
const struct cred *cred = get_task_cred(task);
- struct aa_task_ctx *tctx = current_task_ctx();
+ struct aa_task_ctx *ctx = current_task_ctx();
struct aa_label *label = NULL;
if (strcmp(name, "current") == 0)
label = aa_get_newest_label(cred_label(cred));
- else if (strcmp(name, "prev") == 0 && tctx->previous)
- label = aa_get_newest_label(tctx->previous);
- else if (strcmp(name, "exec") == 0 && tctx->onexec)
- label = aa_get_newest_label(tctx->onexec);
+ else if (strcmp(name, "prev") == 0 && ctx->previous)
+ label = aa_get_newest_label(ctx->previous);
+ else if (strcmp(name, "exec") == 0 && ctx->onexec)
+ label = aa_get_newest_label(ctx->onexec);
else
error = -EINVAL;
@@ -1033,14 +1033,14 @@ static int param_set_mode(const char *val, const struct kernel_param *kp)
static int __init set_init_ctx(void)
{
struct cred *cred = (struct cred *)current->real_cred;
- struct aa_task_ctx *tctx;
+ struct aa_task_ctx *ctx;
- tctx = aa_alloc_task_ctx(GFP_KERNEL);
- if (!tctx)
+ ctx = aa_alloc_task_ctx(GFP_KERNEL);
+ if (!ctx)
return -ENOMEM;
cred_label(cred) = aa_get_label(ns_unconfined(root_ns));
- task_ctx(current) = tctx;
+ task_ctx(current) = ctx;
return 0;
}