From 1aed810c86069f8b9b117ccccf083e98bf0da74c Mon Sep 17 00:00:00 2001 From: Dmitry Vyukov Date: Tue, 8 Apr 2025 14:11:26 +0200 Subject: tools/syz-declextract: extend test data Add few interesting cases for scope analysis. Move functions related to resource to the header file, they must be visible in every file to work. --- tools/syz-declextract/testdata/include/fs.h | 12 +++++++++--- 1 file changed, 9 insertions(+), 3 deletions(-) (limited to 'tools/syz-declextract/testdata/include') diff --git a/tools/syz-declextract/testdata/include/fs.h b/tools/syz-declextract/testdata/include/fs.h index 33782d1ee..b4eba0bd7 100644 --- a/tools/syz-declextract/testdata/include/fs.h +++ b/tools/syz-declextract/testdata/include/fs.h @@ -11,7 +11,13 @@ struct file_operations { void (*mmap)(void); }; -int alloc_fd(); -void __fget_light(int fd); -int from_kuid(); +static int alloc_fd() { + return 1; +} +static void __fget_light(int fd) { +} + +static int from_kuid() { + return 1; +} -- cgit mrf-deployment