linux/tools/testing/selftests/landlock
Hu Yadi 40b7835e74
selftests/landlock: Fix fs_test build with old libc
One issue comes up while building selftest/landlock/fs_test on my side
(gcc 7.3/glibc-2.28/kernel-4.19).

gcc -Wall -O2 -isystem   fs_test.c -lcap -o selftests/landlock/fs_test
fs_test.c:4575:9: error: initializer element is not constant
  .mnt = mnt_tmp,
         ^~~~~~~

Signed-off-by: Hu Yadi <hu.yadi@h3c.com>
Suggested-by: Jiao <jiaoxupo@h3c.com>
Reviewed-by: Berlin <berlin@h3c.com>
Link: https://lore.kernel.org/r/20240124022908.42100-1-hu.yadi@h3c.com
Fixes: 04f9070e99 ("selftests/landlock: Add tests for pseudo filesystems")
[mic: Factor out mount's data string and make mnt_tmp static]
Signed-off-by: Mickaël Salaün <mic@digikod.net>
2024-01-25 16:49:08 +01:00
..
.gitignore
base_test.c landlock: Support network rules with TCP bind and connect 2023-10-26 21:07:15 +02:00
common.h selftests/landlock: Add network tests 2023-10-26 21:07:16 +02:00
config selftests/landlock: Add network tests 2023-10-26 21:07:16 +02:00
config.um selftests/landlock: Add hostfs tests 2023-06-12 21:26:23 +02:00
fs_test.c selftests/landlock: Fix fs_test build with old libc 2024-01-25 16:49:08 +01:00
Makefile selftests/landlock: Build without static libraries 2022-10-19 22:10:56 +02:00
net_test.c selftests/landlock: Fix net_test build with old libc 2024-01-25 16:49:04 +01:00
ptrace_test.c selftests/landlock: Test ptrace as much as possible with Yama 2023-01-27 18:53:55 +01:00
true.c