lsm: use default hook return value in call_int_hook()
authorOndrej Mosnacek <omosnace@redhat.com>
Tue, 30 Jan 2024 12:56:59 +0000 (13:56 +0100)
committerPaul Moore <paul@paul-moore.com>
Thu, 22 Feb 2024 21:52:22 +0000 (16:52 -0500)
commit260017f31a8c3879be5f9048a46f382b06c1923a
tree8ba8bb6548a56f1c6995e2938517e9a21c7d22d0
parent936615f63768482be942644dd3b1b1dca862f25b
lsm: use default hook return value in call_int_hook()

Change the definition of call_int_hook() to treat LSM_RET_DEFAULT(...)
as the "continue" value instead of 0. To further simplify this macro,
also drop the IRC argument and replace it with LSM_RET_DEFAULT(...).

After this the macro can be used in a couple more hooks, where similar
logic is currently open-coded. At the same time, some other existing
call_int_hook() users now need to be open-coded, but overall it's still
a net simplification.

There should be no functional change resulting from this patch.

Signed-off-by: Ondrej Mosnacek <omosnace@redhat.com>
Reviewed-by: Casey Schaufler <casey@schaufler-ca.com>
[PM: merge fuzz due to other hook changes, tweaks from list discussion]
Signed-off-by: Paul Moore <paul@paul-moore.com>
security/security.c