summaryrefslogtreecommitdiffstats
path: root/iptables-save.c
diff options
context:
space:
mode:
authorJan Engelhardt <jengelh@medozas.de>2008-11-10 17:00:41 +0100
committerPatrick McHardy <kaber@trash.net>2008-11-10 17:00:41 +0100
commit1c9015b2cb483678f153121255e10ec0bbfde3e6 (patch)
treeceb7afdf25de51701556fffc7469bc7c4c270570 /iptables-save.c
parentfd1873110f8e57be578df17fc9d03536b10f4f73 (diff)
libiptc: remove indirections
Signed-off-by: Jan Engelhardt <jengelh@medozas.de> Signed-off-by: Patrick McHardy <kaber@trash.net>
Diffstat (limited to 'iptables-save.c')
-rw-r--r--iptables-save.c18
1 files changed, 9 insertions, 9 deletions
diff --git a/iptables-save.c b/iptables-save.c
index 52b85d82..6252c0b0 100644
--- a/iptables-save.c
+++ b/iptables-save.c
@@ -79,15 +79,15 @@ static int do_output(const char *tablename)
/* Dump out chain names first,
* thereby preventing dependency conflicts */
- for (chain = iptc_first_chain(&h);
+ for (chain = iptc_first_chain(h);
chain;
- chain = iptc_next_chain(&h)) {
+ chain = iptc_next_chain(h)) {
printf(":%s ", chain);
if (iptc_builtin(chain, h)) {
struct ipt_counters count;
printf("%s ",
- iptc_get_policy(chain, &count, &h));
+ iptc_get_policy(chain, &count, h));
printf("[%llu:%llu]\n", (unsigned long long)count.pcnt, (unsigned long long)count.bcnt);
} else {
printf("- [0:0]\n");
@@ -95,16 +95,16 @@ static int do_output(const char *tablename)
}
- for (chain = iptc_first_chain(&h);
+ for (chain = iptc_first_chain(h);
chain;
- chain = iptc_next_chain(&h)) {
+ chain = iptc_next_chain(h)) {
const struct ipt_entry *e;
/* Dump out rules */
- e = iptc_first_rule(chain, &h);
+ e = iptc_first_rule(chain, h);
while(e) {
- print_rule(e, &h, chain, show_counters);
- e = iptc_next_rule(e, &h);
+ print_rule(e, h, chain, show_counters);
+ e = iptc_next_rule(e, h);
}
}
@@ -116,7 +116,7 @@ static int do_output(const char *tablename)
exit_error(OTHER_PROBLEM, "Binary NYI\n");
}
- iptc_free(&h);
+ iptc_free(h);
return 1;
}