summaryrefslogtreecommitdiff
path: root/src
diff options
context:
space:
mode:
authorMichael Scherer <misc@zarb.org>2014-02-06 10:05:17 +0100
committerLennart Poettering <lennart@poettering.net>2014-02-10 13:18:16 +0100
commit5c56a259e07661a66e806cc2fbc71de96a75f78e (patch)
tree28876e4b625888a5d61cdbe51a80366ceecdc0d5 /src
parent7b52a628f8b43ba521c302a7f32bccf9d0dc8bfd (diff)
exec: Ignore the setting SELinuxContext if selinux is not enabled
Diffstat (limited to 'src')
-rw-r--r--src/core/execute.c2
1 files changed, 1 insertions, 1 deletions
diff --git a/src/core/execute.c b/src/core/execute.c
index c02c768c68..474a4af895 100644
--- a/src/core/execute.c
+++ b/src/core/execute.c
@@ -1569,7 +1569,7 @@ int exec_spawn(ExecCommand *command,
}
}
#ifdef HAVE_SELINUX
- if (context->selinux_context) {
+ if (context->selinux_context && use_selinux()) {
err = security_check_context(context->selinux_context);
if (err < 0) {
r = EXIT_SELINUX_CONTEXT;