libc, librthread: _twait: fully validate absolute timeout
authorcheloha <cheloha@openbsd.org>
Wed, 8 Nov 2023 15:51:28 +0000 (15:51 +0000)
committercheloha <cheloha@openbsd.org>
Wed, 8 Nov 2023 15:51:28 +0000 (15:51 +0000)
commite1454560cfa22c040bfbb5896d633a6c7213deb2
treedc8266539fd93386e4bf031133a758463b9e017a
parent4ac41129088538915cae0fb0235a2848dc3e2ad3
libc, librthread: _twait: fully validate absolute timeout

Use timespecisvalid(3) to check both bounds for tv_nsec.

Link: https://marc.info/?l=openbsd-tech&m=169913314230496&w=2
ok miod@
lib/libc/thread/synch.h
lib/librthread/synch.h