From 0124019fb36859a77c32b6f96eeb4cc3e8ebb432 Mon Sep 17 00:00:00 2001 From: Phil Sutter Date: Thu, 2 Jun 2022 10:53:31 +0200 Subject: libxtables: Move struct xtables_afinfo into xtables.h The library "owns" this structure and maintains 'afinfo' pointer to instances of it. With libxt_set, there's even an extension making use of the data. To avoid impact on library users, guard it by XTABLES_INTERNAL. To eliminate the xshared.h include by libxt_set, DEBUGP has to be redefined. Other extensions have similar defines, fix this later. Signed-off-by: Phil Sutter --- extensions/libxt_set.c | 6 ++++++ extensions/libxt_set.h | 1 - 2 files changed, 6 insertions(+), 1 deletion(-) (limited to 'extensions') diff --git a/extensions/libxt_set.c b/extensions/libxt_set.c index 16921023..a2137ab1 100644 --- a/extensions/libxt_set.c +++ b/extensions/libxt_set.c @@ -22,6 +22,12 @@ #include #include "libxt_set.h" +#ifdef DEBUG +#define DEBUGP(x, args...) fprintf(stderr, x, ## args) +#else +#define DEBUGP(x, args...) +#endif + /* Revision 0 */ static void diff --git a/extensions/libxt_set.h b/extensions/libxt_set.h index ad895a75..597bf7eb 100644 --- a/extensions/libxt_set.h +++ b/extensions/libxt_set.h @@ -6,7 +6,6 @@ #include #include #include -#include "../iptables/xshared.h" static int get_version(unsigned *version) -- cgit v1.2.3