Details
- Reviewers
kp
Diff Detail
- Repository
- rG FreeBSD src repository
- Lint
Lint Skipped - Unit
Tests Skipped
Event Timeline
No objection, but things just build even on LINT-NOINET6 kernels without this change, so I'm not sure what the motivation is.
I've seen such ifdefs around code in other places in pf, AFAIR the commits were labelled as "fix build without IPv4", so I thought it's always necessary.
In this case we're not using anything that's not available on NOINET/NOINET6, so we don't actually need these here.
There's a fair amount of pf's IPv6 related code that's still present in NOINET6 builds, because it doesn't cause any problems. We're certainly not consistent about adding ifdefs everywhere they're conceptually correct (such as here), but not required. On the whole I think I prefer not having them when we don't need them, because they're just extra lines of code that only save us a handful of bytes of .text.
I usually (but not always, there's plenty of 'fix build' commits from me in the tree) run a make universe before pushing significant changes to catch when we do need the ifdefs.