Page MenuHomeFreeBSD

Fix kvm bitmap index
AbandonedPublic

Authored by luporl on Sep 6 2019, 5:43 PM.
Tags
None
Referenced Files
Unknown Object (File)
Thu, Apr 11, 10:14 AM
Unknown Object (File)
Mon, Apr 8, 4:14 PM
Unknown Object (File)
Feb 2 2024, 3:51 AM
Unknown Object (File)
Jan 2 2024, 7:54 PM
Unknown Object (File)
Dec 20 2023, 2:35 AM
Unknown Object (File)
Dec 11 2023, 3:44 AM
Unknown Object (File)
Dec 3 2023, 6:19 AM
Unknown Object (File)
Oct 22 2023, 2:52 PM
Subscribers

Details

Reviewers
will
emaste
Summary

_kvm_bitmap_next may perform an out-of-bounds access on bm->map array.
It seems the right is to divide *idx by CHAR_BIT, instead of multiplying it.

Another thing that looks strange to me is the function returning when it finds a bit that is not set. Shouldn't it be the opposite?

Diff Detail

Lint
Lint Passed
Unit
No Test Coverage
Build Status
Buildable 26319
Build 24798: arc lint + arc unit