diff options
Diffstat (limited to 'iptables.c')
-rw-r--r-- | iptables.c | 16 |
1 files changed, 8 insertions, 8 deletions
@@ -771,10 +771,10 @@ make_delete_mask(const struct xtables_rule_match *matches, size = sizeof(struct ipt_entry); for (matchp = matches; matchp; matchp = matchp->next) - size += IPT_ALIGN(sizeof(struct ipt_entry_match)) + matchp->match->size; + size += XT_ALIGN(sizeof(struct ipt_entry_match)) + matchp->match->size; mask = xtables_calloc(1, size - + IPT_ALIGN(sizeof(struct ipt_entry_target)) + + XT_ALIGN(sizeof(struct ipt_entry_target)) + target->size); memset(mask, 0xFF, sizeof(struct ipt_entry)); @@ -782,13 +782,13 @@ make_delete_mask(const struct xtables_rule_match *matches, for (matchp = matches; matchp; matchp = matchp->next) { memset(mptr, 0xFF, - IPT_ALIGN(sizeof(struct ipt_entry_match)) + XT_ALIGN(sizeof(struct ipt_entry_match)) + matchp->match->userspacesize); - mptr += IPT_ALIGN(sizeof(struct ipt_entry_match)) + matchp->match->size; + mptr += XT_ALIGN(sizeof(struct ipt_entry_match)) + matchp->match->size; } memset(mptr, 0xFF, - IPT_ALIGN(sizeof(struct ipt_entry_target)) + XT_ALIGN(sizeof(struct ipt_entry_target)) + target->userspacesize); return mask; @@ -1330,7 +1330,7 @@ static void command_default(struct iptables_command_state *cs) cs->proto_used = 1; - size = IPT_ALIGN(sizeof(struct ipt_entry_match)) + m->size; + size = XT_ALIGN(sizeof(struct ipt_entry_match)) + m->size; m->m = xtables_calloc(1, size); m->m->u.match_size = size; @@ -1376,7 +1376,7 @@ static void command_jump(struct iptables_command_state *cs) if (cs->target == NULL) return; - size = IPT_ALIGN(sizeof(struct ipt_entry_target)) + size = XT_ALIGN(sizeof(struct ipt_entry_target)) + cs->target->size; cs->target->t = xtables_calloc(1, size); @@ -1407,7 +1407,7 @@ static void command_match(struct iptables_command_state *cs) "unexpected ! flag before --match"); m = xtables_find_match(optarg, XTF_LOAD_MUST_SUCCEED, &cs->matches); - size = IPT_ALIGN(sizeof(struct ipt_entry_match)) + m->size; + size = XT_ALIGN(sizeof(struct ipt_entry_match)) + m->size; m->m = xtables_calloc(1, size); m->m->u.match_size = size; strcpy(m->m->u.user.name, m->name); |