entry_before = before->data;
/*
- * We've just insterted a new entry. All references before it
+ * We've just appended/insterted a new entry. All references
* should be bumped accordingly.
*/
- for (list = table->entries; list != before; list = list->next) {
+ for (list = table->entries; list; list = list->next) {
tmp = list->data;
if (!is_jump(tmp))
t = (struct xt_standard_target *)ipt_get_target(tmp->entry);
- if (t->verdict >= entry_before->offset)
+ if (t->verdict > entry_before->offset)
t->verdict += entry->next_offset;
}