aboutsummaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
authorThomas Meyer <thomas@m3y3r.de>2017-10-07 10:02:21 -0400
committerJohn Johansen <john.johansen@canonical.com>2017-11-21 05:17:12 -0500
commit954317fef2ee789af55f82903dbc574905250f7c (patch)
tree70ced9c6a2a47e3cdb50e0abf878a994b21d019e
parent7bba39ae52c4d7b467d0a6f74cc067a561aac043 (diff)
apparmor: Fix bool initialization/comparison
Bool initializations should use true and false. Bool tests don't need comparisons. Signed-off-by: Thomas Meyer <thomas@m3y3r.de> Signed-off-by: John Johansen <john.johansen@canonical.com>
-rw-r--r--security/apparmor/lsm.c8
1 files changed, 4 insertions, 4 deletions
diff --git a/security/apparmor/lsm.c b/security/apparmor/lsm.c
index 1346ee5be04f..a2fb2de5611a 100644
--- a/security/apparmor/lsm.c
+++ b/security/apparmor/lsm.c
@@ -846,7 +846,7 @@ module_param_call(audit, param_set_audit, param_get_audit,
846/* Determines if audit header is included in audited messages. This 846/* Determines if audit header is included in audited messages. This
847 * provides more context if the audit daemon is not running 847 * provides more context if the audit daemon is not running
848 */ 848 */
849bool aa_g_audit_header = 1; 849bool aa_g_audit_header = true;
850module_param_named(audit_header, aa_g_audit_header, aabool, 850module_param_named(audit_header, aa_g_audit_header, aabool,
851 S_IRUSR | S_IWUSR); 851 S_IRUSR | S_IWUSR);
852 852
@@ -871,7 +871,7 @@ module_param_named(path_max, aa_g_path_max, aauint, S_IRUSR);
871 * DEPRECATED: read only as strict checking of load is always done now 871 * DEPRECATED: read only as strict checking of load is always done now
872 * that none root users (user namespaces) can load policy. 872 * that none root users (user namespaces) can load policy.
873 */ 873 */
874bool aa_g_paranoid_load = 1; 874bool aa_g_paranoid_load = true;
875module_param_named(paranoid_load, aa_g_paranoid_load, aabool, S_IRUGO); 875module_param_named(paranoid_load, aa_g_paranoid_load, aabool, S_IRUGO);
876 876
877/* Boot time disable flag */ 877/* Boot time disable flag */
@@ -1119,7 +1119,7 @@ static int __init apparmor_init(void)
1119 1119
1120 if (!apparmor_enabled || !security_module_enable("apparmor")) { 1120 if (!apparmor_enabled || !security_module_enable("apparmor")) {
1121 aa_info_message("AppArmor disabled by boot time parameter"); 1121 aa_info_message("AppArmor disabled by boot time parameter");
1122 apparmor_enabled = 0; 1122 apparmor_enabled = false;
1123 return 0; 1123 return 0;
1124 } 1124 }
1125 1125
@@ -1175,7 +1175,7 @@ alloc_out:
1175 aa_destroy_aafs(); 1175 aa_destroy_aafs();
1176 aa_teardown_dfa_engine(); 1176 aa_teardown_dfa_engine();
1177 1177
1178 apparmor_enabled = 0; 1178 apparmor_enabled = false;
1179 return error; 1179 return error;
1180} 1180}
1181 1181