[PATCH v1 2/2] selftests/landlock: Fix disconnected variant formatting

Günther Noack gnoack at google.com
Fri Sep 11 12:48:50 UTC 2026


On Mon, Sep 07, 2026 at 06:07:07PM +0200, Mickaël Salaün wrote:
> The s3d1_s4d1_disconnected_rename_even variant is missing the formatting
> guard used by its neighbors.  This leaves its opening brace attached to
> the FIXTURE_VARIANT_ADD() invocation and its clang-format enable marker
> unmatched.
> 
> Restore the per-variant guard.  End it after the macro header so the
> initializer remains managed by clang-format.
> 
> Cc: Günther Noack <gnoack at google.com>
> Signed-off-by: Mickaël Salaün <mic at digikod.net>
> ---
>  tools/testing/selftests/landlock/fs_test.c | 3 ++-
>  1 file changed, 2 insertions(+), 1 deletion(-)
> 
> diff --git a/tools/testing/selftests/landlock/fs_test.c b/tools/testing/selftests/landlock/fs_test.c
> index 18dbdb99aeba..d0be84e572f5 100644
> --- a/tools/testing/selftests/landlock/fs_test.c
> +++ b/tools/testing/selftests/landlock/fs_test.c
> @@ -5958,8 +5958,9 @@ FIXTURE_VARIANT_ADD(layout4_disconnected_leafs, s3d1_s4d1_new_parent_create) {
>  	.expected_exchange_result = EXDEV,
>  };
>  
> +/* clang-format off */
>  FIXTURE_VARIANT_ADD(layout4_disconnected_leafs,
> -		    s3d1_s4d1_disconnected_rename_even){
> +		    s3d1_s4d1_disconnected_rename_even) {
>  	/* clang-format on */
>  	.allowed_s3d1 = LANDLOCK_ACCESS_FS_REFER | LANDLOCK_ACCESS_FS_MAKE_REG,
>  	.allowed_s4d1 = LANDLOCK_ACCESS_FS_REFER | LANDLOCK_ACCESS_FS_MAKE_REG,
> -- 
> 2.55.0
> 

Reviewed-by: Günther Noack <gnoack at google.com>



More information about the Linux-security-module-archive mailing list