HomeFreeBSD

osd: Fix racy assertions

Description

osd: Fix racy assertions

osd_register(9) may reallocate and expand the destructor array for a
given object type if no space is available for a new key. This happens
with the object lock held. Thus, when verifying that a given slot in
the array is occupied, we need to hold the object lock to avoid racing
with a reallocation.

Reported by: syzbot+69ce54c7d7d813315dd3@syzkaller.appspotmail.com
MFC after: 1 week
Sponsored by: The FreeBSD Foundation

Details

Provenance
markjAuthored on Sep 9 2021, 1:50 PM
Parents
rGb645ee1815da: openssh: remove update notes about upstreamed changes
Branches
Unknown
Tags
Unknown