]> CyberLeo.Net >> Repos - FreeBSD/FreeBSD.git/commit
libc: implement rtld_get_stack_prot() for real
authorKonstantin Belousov <kib@FreeBSD.org>
Sun, 10 Jan 2021 03:05:42 +0000 (05:05 +0200)
committerKonstantin Belousov <kib@FreeBSD.org>
Sun, 10 Jan 2021 06:25:43 +0000 (08:25 +0200)
commit81b3a0a34145ee6c855f50c8035728f76d63c3f0
tree1303332e65b06d659d53737b49683ed4d60bb3fe
parent2a4b225146353351c6af4a1904dca6ee9a433341
libc: implement rtld_get_stack_prot() for real

which makes stack prot correct for non-main threads created by binaries
with statically linked libthr.

Cache result, but do not engage into the full double-checked locking,
since calculation of the return value is idempotent.

PR: 252549
Reported and reviewed by: emaste
MFC after: 1 week
Sponsored by: The FreeBSD Foundation
Differential Revision: https://reviews.freebsd.org/D28075
lib/libc/gen/dlfcn.c