diff options
author | Florian Westphal <fw@strlen.de> | 2019-09-16 13:57:45 +0200 |
---|---|---|
committer | Florian Westphal <fw@strlen.de> | 2019-09-16 14:16:20 +0200 |
commit | 7f97513ae2532c62854084e914a517ea79ad3b31 (patch) | |
tree | 727eeccfebd6ecac7b93fbe429cfe327e7478788 /libiptc/libiptc.c | |
parent | 1b5d762c1865e425ee22a7453bdb62bd5154fee7 (diff) |
libiptc: axe non-building debug code
hasn't built with IPTC_DEBUG=1 since at least 2004, so remove it.
Closes: https://bugzilla.netfilter.org/show_bug.cgi?id=1275
Signed-off-by: Florian Westphal <fw@strlen.de>
Diffstat (limited to 'libiptc/libiptc.c')
-rw-r--r-- | libiptc/libiptc.c | 14 |
1 files changed, 0 insertions, 14 deletions
diff --git a/libiptc/libiptc.c b/libiptc/libiptc.c index f4fb09fb..ee2b8521 100644 --- a/libiptc/libiptc.c +++ b/libiptc/libiptc.c @@ -188,14 +188,6 @@ set_changed(struct xtc_handle *h) h->changed = 1; } -#ifdef IPTC_DEBUG -static void do_check(struct xtc_handle *h, unsigned int line); -#define CHECK(h) do { if (!getenv("IPTC_NO_CHECK")) do_check((h), __LINE__); } while(0) -#else -#define CHECK(h) -#endif - - /********************************************************************** * iptc blob utility functions (iptcb_*) **********************************************************************/ @@ -1370,7 +1362,6 @@ retry: if (parse_table(h) < 0) goto error; - CHECK(h); return h; error: TC_FREE(h); @@ -1417,7 +1408,6 @@ void TC_DUMP_ENTRIES(struct xtc_handle *const handle) { iptc_fn = TC_DUMP_ENTRIES; - CHECK(handle); printf("libiptc v%s. %u bytes.\n", XTABLES_VERSION, handle->entries->size); @@ -2152,7 +2142,6 @@ TC_READ_COUNTER(const IPT_CHAINLABEL chain, struct rule_head *r; iptc_fn = TC_READ_COUNTER; - CHECK(*handle); if (!(c = iptcc_find_label(chain, handle))) { errno = ENOENT; @@ -2176,7 +2165,6 @@ TC_ZERO_COUNTER(const IPT_CHAINLABEL chain, struct rule_head *r; iptc_fn = TC_ZERO_COUNTER; - CHECK(handle); if (!(c = iptcc_find_label(chain, handle))) { errno = ENOENT; @@ -2207,7 +2195,6 @@ TC_SET_COUNTER(const IPT_CHAINLABEL chain, STRUCT_ENTRY *e; iptc_fn = TC_SET_COUNTER; - CHECK(handle); if (!(c = iptcc_find_label(chain, handle))) { errno = ENOENT; @@ -2532,7 +2519,6 @@ TC_COMMIT(struct xtc_handle *handle) unsigned int new_size; iptc_fn = TC_COMMIT; - CHECK(*handle); /* Don't commit if nothing changed. */ if (!handle->changed) |