summaryrefslogtreecommitdiff
path: root/scripts/Makefile.thinlto
diff options
context:
space:
mode:
authorMickaël Salaün <mic@digikod.net>2026-09-07 12:36:08 +0200
committerMickaël Salaün <mic@digikod.net>2026-09-07 12:38:04 +0200
commite1e60f71f54f2cdff687fc7a6ca3f35ad7b9c75d (patch)
tree450ef3879d970a84ef7c7d3c0c06536f0b28fda7 /scripts/Makefile.thinlto
parente7557b9ef7a87570cbd0873a163de05bde80c39b (diff)
downloadlinux-next-e1e60f71f54f2cdff687fc7a6ca3f35ad7b9c75d.tar.gz
linux-next-e1e60f71f54f2cdff687fc7a6ca3f35ad7b9c75d.zip
landlock: Clean up ruleset validation checks
landlock_merge_ruleset() checks for a NULL ruleset after dereferencing it in lockdep_assert_held(). Move the assertion after the check so the defensive path remains effective. The mask-validation comment originated in landlock_add_fs_access_mask() to explain that its WARN_ON_ONCE() checked a caller invariant. It became self-referential when this helper and its network and scope counterparts were inlined into landlock_create_ruleset(). Restate the invariant without naming the caller. Keep both as defensive callee checks. Moving the assertion preserves the NULL check's ability to warn and return -EINVAL, while invalid masks remain warned about and masked. Reported-by: Günther Noack <gnoack@google.com> Closes: https://patch.msgid.link/aobYhIt3vcs2xN0b@google.com Closes: https://patch.msgid.link/aobasxUDQ8b7GYXl@google.com Link: https://patch.msgid.link/20260907103609.113325-1-mic@digikod.net Signed-off-by: Mickaël Salaün <mic@digikod.net>
Diffstat (limited to 'scripts/Makefile.thinlto')
0 files changed, 0 insertions, 0 deletions