From: Lennart Poettering Date: Sun, 3 Apr 2011 20:18:35 +0000 (+0200) Subject: condition: use 'selinux' rather than 'SELinux' as preferred spelling X-Git-Tag: v23~16 X-Git-Url: https://err.no/cgi-bin/gitweb.cgi?a=commitdiff_plain;h=d24e1b4806e7e96b0c5bc0950ce79e8f76c2ab71;p=systemd condition: use 'selinux' rather than 'SELinux' as preferred spelling The virtualization condition and others use lowercase identifiers, so for the sake of keeping things least surprising, use lowercase identifiers here too. --- diff --git a/man/systemd.unit.xml b/man/systemd.unit.xml index 73968067..5460ebeb 100644 --- a/man/systemd.unit.xml +++ b/man/systemd.unit.xml @@ -634,7 +634,7 @@ may be used to check whether the given security module is enabled on the system. Currently the only recognized value is - SELinux. + selinux. The test may be negated by prepending an exclamation mark. Finally, ConditionNull= may diff --git a/src/condition.c b/src/condition.c index ee0809f7..a520e434 100644 --- a/src/condition.c +++ b/src/condition.c @@ -134,7 +134,7 @@ static bool test_virtualization(const char *parameter) { static bool test_security(const char *parameter) { #ifdef HAVE_SELINUX - if (!strcasecmp(parameter, "SELinux")) + if (streq(parameter, "selinux")) return is_selinux_enabled() > 0; #endif return false;