Page MenuHomeFreeBSD

devfs: Avoid comparison with an uninitialized var in devfs_fp_check()
ClosedPublic

Authored by markj on May 1 2021, 2:19 PM.
Tags
None
Referenced Files
Unknown Object (File)
Apr 30 2024, 10:26 AM
Unknown Object (File)
Apr 27 2024, 8:06 PM
Unknown Object (File)
Apr 19 2024, 5:30 PM
Unknown Object (File)
Feb 5 2024, 10:56 PM
Unknown Object (File)
Jan 1 2024, 11:21 PM
Unknown Object (File)
Dec 14 2023, 4:27 AM
Unknown Object (File)
Dec 12 2023, 12:19 AM
Unknown Object (File)
Oct 7 2023, 10:28 PM
Subscribers

Details

Summary

devvn_refthread() will initialize *devp only if it suceeds, so check for
success before comparing with fp->f_data. Other devfs_fp_check()
callers are careful to do this.

Reported by: KMSAN

Diff Detail

Repository
rS FreeBSD src repository - subversion
Lint
Lint Passed
Unit
No Test Coverage
Build Status
Buildable 38954
Build 35843: arc lint + arc unit