diff options
author | Alice Frosi <afrosi@redhat.com> | 2023-05-16 18:05:46 +0200 |
---|---|---|
committer | Alice Frosi <afrosi@redhat.com> | 2023-05-17 10:55:11 +0200 |
commit | 16346c99a674d95970cfc59b0aa5d00e91cc4e0f (patch) | |
tree | c10f01f1d33108ac17bec484ac570e4a431ded0b /tests/unit/testutil.h | |
parent | aeaeda81af25fdc105d4157dc9e679423fdef761 (diff) | |
download | seitan-16346c99a674d95970cfc59b0aa5d00e91cc4e0f.tar seitan-16346c99a674d95970cfc59b0aa5d00e91cc4e0f.tar.gz seitan-16346c99a674d95970cfc59b0aa5d00e91cc4e0f.tar.bz2 seitan-16346c99a674d95970cfc59b0aa5d00e91cc4e0f.tar.lz seitan-16346c99a674d95970cfc59b0aa5d00e91cc4e0f.tar.xz seitan-16346c99a674d95970cfc59b0aa5d00e91cc4e0f.tar.zst seitan-16346c99a674d95970cfc59b0aa5d00e91cc4e0f.zip |
filter: refactoring filter
Attempt to simplify the filter build:
- storing all the bpf_args in a common array and saving the index of
each entry in filter_input
- added new flag to filter_add_arg for append an argument to an entry
- split large loop in filter_build in multiple functions
- adjust and refactor tests/units/test_filter
The tests in test_filter_build.c still need to be fixed
Diffstat (limited to 'tests/unit/testutil.h')
-rw-r--r-- | tests/unit/testutil.h | 3 |
1 files changed, 2 insertions, 1 deletions
diff --git a/tests/unit/testutil.h b/tests/unit/testutil.h index 638dd0a..4f104ac 100644 --- a/tests/unit/testutil.h +++ b/tests/unit/testutil.h @@ -55,7 +55,8 @@ struct args_target { bool open_path; int fd; int nr; - struct arg args[6]; + bool filter_args[6]; + struct bpf_arg args[6]; void *targs[6]; int (*install_filter)(struct args_target *at); int (*target)(void *); |