summaryrefslogtreecommitdiff
path: root/tests/fcntl.c
diff options
context:
space:
mode:
authorDmitry V. Levin <ldv@strace.io>2021-02-20 08:00:00 +0000
committerDmitry V. Levin <ldv@strace.io>2021-02-20 08:00:00 +0000
commita093c413b3965c6058e9b58fbf08285da14e2661 (patch)
tree3179a83a777f32d4032b3fb5647bd6ac966722ca /tests/fcntl.c
parent87859aa1d7541afc0ba46114903b660e3870eb4f (diff)
downloadstrace-a093c413b3965c6058e9b58fbf08285da14e2661.tar.gz
Switch to use bundled <linux/fcntl.h>
* bundled/linux/include/uapi/linux/fcntl.h: New file, copied from headers_install'ed Linux kernel v5.11. * bundled/Makefile.am (EXTRA_DIST): Add it. * configure.ac (AC_CHECK_TYPES): Remove struct flock, struct flock64, struct __kernel_flock, struct __kernel_flock64, struct f_owner_ex, and struct __kernel_f_owner_ex. * src/f_owner_ex.h: Remove. * src/flock.h: Likewise. * src/Makefile.am (libstrace_a_SOURCES): Remove f_owner_ex.h and flock.h. * src/fcntl.c: Include <linux/fcntl.h> instead of "flock.h". (print_struct_flock64, printflock64, printflock): Replace struct_kernel_flock64 with struct flock64. * src/fetch_struct_flock.c: Include <linux/fcntl.h> instead of "flock.h". Replace struct_kernel_flock64 with struct flock64 and struct_kernel_flock with struct flock. * src/file_handle.c: Include <linux/fcntl.h>. * src/open.c: Likewise. * src/open_tree.c: Likewise. * src/statx.c: Likewise. * src/link.c: Include <linux/fcntl.h> instead of <fcntl.h>. * src/xlat/at_flags.in: Add #unconditional, remove fallback definitions. * src/xlat/f_owner_types.in: Likewise. * src/xlat/f_seals.in: Likewise. * src/xlat/fcntlcmds.in: Likewise. * src/xlat/name_to_handle_at_flags.in: Likewise. * src/xlat/open_tree_flags.in: Likewise. * src/xlat/fdflags.in: Add #unconditional. * src/xlat/lockfcmds.in: Likewise. * src/xlat/notifyflags.in: Likewise. * tests/fcntl-common.c: Include <linux/fcntl.h> instead of "flock.h", do not include "f_owner_ex.h", always define and invoke test_f_owner_ex, assume <linux/fcntl.h> defines all its types and constants, replace struct_kernel_flock64 with struct flock64, struct_kernel_flock with struct flock, and struct_kernel_f_owner_ex with struct f_owner_ex. * tests/fcntl.c (test_flock64_undecoded): Replace struct_kernel_flock64 with struct flock64. * tests/fcntl64.c (test_flock64_lk64): Likewise. * tests/openat2.c: Include <linux/fcntl.h>, assume it defines all its types and constants.
Diffstat (limited to 'tests/fcntl.c')
-rw-r--r--tests/fcntl.c2
1 files changed, 1 insertions, 1 deletions
diff --git a/tests/fcntl.c b/tests/fcntl.c
index a0d192f55..3fdab90a3 100644
--- a/tests/fcntl.c
+++ b/tests/fcntl.c
@@ -18,7 +18,7 @@
static void
test_flock64_undecoded(const int cmd, const char *name)
{
- struct_kernel_flock64 fl = {
+ struct flock64 fl = {
.l_type = F_RDLCK,
.l_start = 0xdefaced1facefeedULL,
.l_len = 0xdefaced2cafef00dULL