HomeFreeBSD

pf: explicitly NULL state key pointers

Description

pf: explicitly NULL state key pointers

After the pf_state_insert() call we may not use these pointers again.
Explicitly NULL them to ensure we don't.
Also NULL them out if we free the keys directly.

Reviewed by: glebius, markj
MFC after: 3 weeks
Sponsored by: Rubicon Communications, LLC ("Netgate")
Differential Revision: https://reviews.freebsd.org/D49553

(cherry picked from commit 592418343348bcf4355c249f53cff89ed90ea1f5)

Details

Provenance
kpAuthored on Mar 27 2025, 2:37 PM
Reviewer
glebius
Differential Revision
D49553: pf: explicitly NULL state key pointers
Parents
rG8b9d1dc82ac4: pf: don't use state keys after pf_state_insert()
Branches
Unknown
Tags
Unknown