Do not modify cmd pointer if it is already last opcode in the rule.
MFC after: 1 week
This commit is contained in:
parent
15268fa047
commit
571b48c044
@ -387,7 +387,7 @@ ipfw_reset_eaction(struct ip_fw_chain *ch, struct ip_fw *rule,
|
||||
while (l > 0) {
|
||||
cmdlen = F_LEN(cmd);
|
||||
l -= cmdlen;
|
||||
if (cmd->opcode == O_EXTERNAL_ACTION)
|
||||
if (cmd->opcode == O_EXTERNAL_ACTION || l <= 0)
|
||||
break;
|
||||
cmd += cmdlen;
|
||||
}
|
||||
|
Loading…
Reference in New Issue
Block a user