From: James Carter <jwcart2@gmail.com>
To: selinux@vger.kernel.org
Cc: cgzones@googlemail.com, James Carter <jwcart2@gmail.com>
Subject: [PATCH] checkpolicy/fuzz: Update check_level() to use notdefined field
Date: Wed, 6 Mar 2024 09:34:51 -0500 [thread overview]
Message-ID: <20240306143451.2256235-1-jwcart2@gmail.com> (raw)
Commit e16f586 (Fix potential double free of mls_level_t) renamed
the "defined" field to "notdefined", but did not update this use of
it.
Use the new field "notdefined" for the check.
Signed-off-by: James Carter <jwcart2@gmail.com>
---
checkpolicy/fuzz/checkpolicy-fuzzer.c | 2 +-
1 file changed, 1 insertion(+), 1 deletion(-)
diff --git a/checkpolicy/fuzz/checkpolicy-fuzzer.c b/checkpolicy/fuzz/checkpolicy-fuzzer.c
index 0d749a02..a3da0b57 100644
--- a/checkpolicy/fuzz/checkpolicy-fuzzer.c
+++ b/checkpolicy/fuzz/checkpolicy-fuzzer.c
@@ -135,7 +135,7 @@ static int check_level(hashtab_key_t key, hashtab_datum_t datum, void *arg __att
const level_datum_t *levdatum = (level_datum_t *) datum;
// TODO: drop member defined if proven to be always set
- if (!levdatum->isalias && !levdatum->defined) {
+ if (!levdatum->isalias && levdatum->notdefined) {
fprintf(stderr,
"Error: sensitivity %s was not used in a level definition!\n",
key);
--
2.44.0
next reply other threads:[~2024-03-06 14:34 UTC|newest]
Thread overview: 3+ messages / expand[flat|nested] mbox.gz Atom feed top
2024-03-06 14:34 James Carter [this message]
2024-03-06 19:22 ` [PATCH] checkpolicy/fuzz: Update check_level() to use notdefined field Christian Göttsche
2024-03-07 14:15 ` James Carter
Reply instructions:
You may reply publicly to this message via plain-text email
using any one of the following methods:
* Save the following mbox file, import it into your mail client,
and reply-to-all from there: mbox
Avoid top-posting and favor interleaved quoting:
https://en.wikipedia.org/wiki/Posting_style#Interleaved_style
* Reply using the --to, --cc, and --in-reply-to
switches of git-send-email(1):
git send-email \
--in-reply-to=20240306143451.2256235-1-jwcart2@gmail.com \
--to=jwcart2@gmail.com \
--cc=cgzones@googlemail.com \
--cc=selinux@vger.kernel.org \
/path/to/YOUR_REPLY
https://kernel.org/pub/software/scm/git/docs/git-send-email.html
* If your mail client supports setting the In-Reply-To header
via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line
before the message body.
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox;
as well as URLs for read-only IMAP folder(s) and NNTP newsgroup(s).