From 3f4b521b05183e9990759106452aa90deeb49354 Mon Sep 17 00:00:00 2001 From: laforge Date: Mon, 30 Aug 2004 16:00:32 +0000 Subject: slightly different semantics of iptc_builtin --- ip6tables-restore.c | 4 ++-- ip6tables.c | 2 +- 2 files changed, 3 insertions(+), 3 deletions(-) diff --git a/ip6tables-restore.c b/ip6tables-restore.c index 906f93e..76dddcb 100644 --- a/ip6tables-restore.c +++ b/ip6tables-restore.c @@ -7,7 +7,7 @@ * Rusty Russell * This code is distributed under the terms of GNU GPL v2 * - * $Id: ip6tables-restore.c,v 1.21 2004/02/02 20:14:56 gandalf Exp $ + * $Id: ip6tables-restore.c,v 1.22 2004/05/26 16:04:48 gandalf Exp $ */ #include @@ -228,7 +228,7 @@ int main(int argc, char *argv[]) exit(1); } - if (!ip6tc_builtin(chain, handle)) { + if (ip6tc_builtin(chain, handle) <= 0) { DEBUGP("Creating new chain '%s'\n", chain); if (!ip6tc_create_chain(chain, &handle)) exit_error(PARAMETER_PROBLEM, diff --git a/ip6tables.c b/ip6tables.c index 257f4ee..4b81e78 100644 --- a/ip6tables.c +++ b/ip6tables.c @@ -1492,7 +1492,7 @@ for_each_chain(int (*fn)(const ip6t_chainlabel, int, ip6tc_handle_t *), for (i = 0; i < chaincount; i++) { if (!builtinstoo && ip6tc_builtin(chains + i*sizeof(ip6t_chainlabel), - *handle)) + *handle) == 1) continue; ret &= fn(chains + i*sizeof(ip6t_chainlabel), verbose, handle); } -- cgit v1.2.3