HomeFreeBSD

tests/tcp_hpts_test: Fix resource leaks

Description

tests/tcp_hpts_test: Fix resource leaks

When a KTEST_EQUAL assertion fails, the test function returns, but this
can cause it to leak locks, which can trigger a panic under witness.
Add a variant which causes control flow to jump to a label in case of
failure, and use that to prevent this problem.

Reviewed by: Nick Banks <nickbanks@netflix.com>, tuexen
MFC after: 1 weeks
Differential Revision: https://reviews.freebsd.org/D56647

Details

Provenance
markjAuthored on Apr 27 2026, 1:17 AM
Reviewer
nick
Differential Revision
D56647: tests/tcp_hpts_test: Fix resource leaks
Parents
rG92e5f6e1995a: x86/ucode: fix gcc uninitialised warning
Branches
Unknown
Tags
Unknown