checkpolicy/0013-checkpolicy-drop-redundant-cast-to-the-same-type.patch
Petr Lautrbach 09820226ae checkpolicy-3.2-3
Rebase on upstream commit 32611aea6543

See
    $ cd SELinuxProject/selinux
    $ git log --pretty=oneline checkpolicy-3.2..32611aea6543 -- checkpolicy
2021-07-28 19:44:56 +02:00

32 lines
929 B
Diff

From 4e3d0990c6be73419df3c32b7de98c992797e3ef Mon Sep 17 00:00:00 2001
From: =?UTF-8?q?Christian=20G=C3=B6ttsche?= <cgzones@googlemail.com>
Date: Tue, 6 Jul 2021 19:54:30 +0200
Subject: [PATCH] checkpolicy: drop redundant cast to the same type
MIME-Version: 1.0
Content-Type: text/plain; charset=UTF-8
Content-Transfer-Encoding: 8bit
Found by clang-tidy.
Signed-off-by: Christian Göttsche <cgzones@googlemail.com>
---
checkpolicy/policy_define.c | 2 +-
1 file changed, 1 insertion(+), 1 deletion(-)
diff --git a/checkpolicy/policy_define.c b/checkpolicy/policy_define.c
index 887857851504..efe3a1a26315 100644
--- a/checkpolicy/policy_define.c
+++ b/checkpolicy/policy_define.c
@@ -1796,7 +1796,7 @@ int define_bool_tunable(int is_tunable)
return -1;
}
- datum->state = (int)(bool_value[0] == 'T') ? 1 : 0;
+ datum->state = (bool_value[0] == 'T') ? 1 : 0;
free(bool_value);
return 0;
cleanup:
--
2.32.0