From: Yu Watanabe Date: Fri, 31 Jul 2026 17:13:58 +0000 (+0900) Subject: core/bpf-restrict-fs: use DEFINE_TRIVIAL_CLEANUP_FUNC_FULL_RENAME macro X-Git-Url: http://git.ipfire.org/?a=commitdiff_plain;h=8292dfdca3418454b442b8a2f3b4cfd38929fab9;p=thirdparty%2Fsystemd.git core/bpf-restrict-fs: use DEFINE_TRIVIAL_CLEANUP_FUNC_FULL_RENAME macro --- diff --git a/src/core/bpf-restrict-fs.c b/src/core/bpf-restrict-fs.c index f435469c30d..04b30519f4f 100644 --- a/src/core/bpf-restrict-fs.c +++ b/src/core/bpf-restrict-fs.c @@ -21,14 +21,8 @@ #define CGROUP_HASH_SIZE_MAX 2048 -static struct restrict_fs_bpf *restrict_fs_bpf_free(struct restrict_fs_bpf *obj) { - /* restrict_fs_bpf__destroy handles object == NULL case */ - restrict_fs_bpf__destroy(obj); - - return NULL; -} - -DEFINE_TRIVIAL_CLEANUP_FUNC(struct restrict_fs_bpf *, restrict_fs_bpf_free); +/* restrict_fs_bpf__destroy handles object == NULL case */ +DEFINE_TRIVIAL_CLEANUP_FUNC_FULL_RENAME(struct restrict_fs_bpf *, restrict_fs_bpf__destroy, restrict_fs_bpf_freep, NULL); int bpf_restrict_fs_setup(Manager *m) { int r;