Page MenuHomeFreeBSD

sys/sysctl.h: Fix wrong assertion with multiple access flags
ClosedPublic

Authored by zlei on Jun 7 2024, 4:46 PM.
Tags
None
Referenced Files
Unknown Object (File)
Mon, Feb 10, 11:40 AM
Unknown Object (File)
Sat, Feb 8, 6:39 PM
Unknown Object (File)
Mon, Feb 3, 1:54 PM
Unknown Object (File)
Jan 10 2025, 10:04 AM
Unknown Object (File)
Dec 25 2024, 10:13 PM
Unknown Object (File)
Nov 19 2024, 2:39 PM
Unknown Object (File)
Nov 19 2024, 2:17 PM
Unknown Object (File)
Oct 26 2024, 3:35 PM
Subscribers

Details

Summary

With multiple flags passed in, e.g., CTLFLAG_RD | CTLFLAG_CAPRD, due to
the precedence rules, this will result in false positive assertion. Fix
that by surrounding the replacement lists with parentheses.

Fixes: 10a1e981d411 iflib: mark isc_driver_version as constant
MFC after: 3 days

Diff Detail

Repository
rG FreeBSD src repository
Lint
Lint Not Applicable
Unit
Tests Not Applicable