Page MenuHomeFreeBSD

sysv_sem: fix the loop that compacts sem array on semaphores removal.
ClosedPublic

Authored by kib on Feb 15 2020, 11:11 AM.
Tags
None
Referenced Files
Unknown Object (File)
Dec 17 2023, 5:53 AM
Unknown Object (File)
Sep 7 2023, 3:06 AM
Unknown Object (File)
Sep 7 2023, 3:04 AM
Unknown Object (File)
Sep 1 2023, 6:50 PM
Unknown Object (File)
Sep 1 2023, 6:32 PM
Unknown Object (File)
Jun 30 2023, 9:01 AM
Unknown Object (File)
Jun 27 2023, 6:36 PM
Unknown Object (File)
Jun 27 2023, 6:34 PM
Subscribers

Details

Summary

As written now, it copies random kernel memory from beyond the bounds of the array.

While there, use designated initialisers for seminfo, and add assert in sem_remove() that sema is sane. [These will be separate commits].

Reported and tested by: pho

Diff Detail

Repository
rS FreeBSD src repository - subversion
Lint
Lint Not Applicable
Unit
Tests Not Applicable