HomeFreeBSD

pf: micro-optimise padding check

Description

pf: micro-optimise padding check

In most cases, IP fragments do not have an Ethernet padding. So
add a condition to save a useless call to m_adj() and have a paranoid
length check in the other cases.
OK henning@

Obtained from: OpenBSD, bluhm <bluhm@openbsd.org>, fcf0d61153
Obtained from: OpenBSD, chris <chris@openbsd.org>, ebe64b684c
Sponsored by: Rubicon Communications, LLC ("Netgate")

Details

Provenance
kpAuthored on Feb 14 2025, 3:23 PM
Parents
rG08d01204175d: snmp_pf: fix rules->label use
Branches
Unknown
Tags
Unknown