return;
list_for_each_entry(ipset, &state->ipsets, list)
- if (!fw3_lookup_ipset(state, ipset->name, true))
- create_ipset(ipset, state);
+ if (!hasbit(ipset->flags[0], FW3_FLAG_DELETED))
+ if (!fw3_lookup_ipset(state, ipset->name, true))
+ create_ipset(ipset, state);
fw3_pr("quit\n");
}
FW3_FLAG_MTU_FIX = 17,
FW3_FLAG_DROP_INVALID = 18,
FW3_FLAG_HOTPLUG = 19,
+ FW3_FLAG_DELETED = 20,
__FW3_FLAG_MAX
};
zone->name = strdup(name);
list_add_tail(&zone->list, &s->zones);
+
+ setbit(flags[0], FW3_FLAG_DELETED);
}
zone->flags[0] = flags[0];
ipset->name = strdup(name);
list_add_tail(&ipset->list, &s->ipsets);
+
+ setbit(flags[0], FW3_FLAG_DELETED);
}
ipset->flags[0] = flags[0];
list_for_each_entry(z, &s->running_zones, running_list)
{
+ if (hasbit(z->flags[0], FW3_FLAG_DELETED))
+ continue;
+
if (fw3_no_table(z->flags[0]) && fw3_no_table(z->flags[1]))
continue;
list_for_each_entry(i, &s->running_ipsets, running_list)
{
+ if (hasbit(z->flags[0], FW3_FLAG_DELETED))
+ continue;
+
if (!fw3_no_family(i->flags[0]) || !fw3_no_family(i->flags[1]))
{
fprintf(sf, "%x %s %x %x\n",
struct fw3_zone *zone;
list_for_each_entry(zone, &state->zones, list)
- print_zone_chain(state, family, table, reload, zone);
+ if (!hasbit(zone->flags[0], FW3_FLAG_DELETED))
+ print_zone_chain(state, family, table, reload, zone);
}
void
struct fw3_zone *zone;
list_for_each_entry(zone, &state->zones, list)
- print_zone_rule(state, family, table, reload, zone);
+ if (!hasbit(zone->flags[0], FW3_FLAG_DELETED))
+ print_zone_rule(state, family, table, reload, zone);
}
void