glibc/sysdeps
Szabolcs Nagy 8d4d77f6c8 arm: Fix an incorrect check in ____longjmp_chk [BZ #27709]
An incorrect check in __longjmp_chk could fail on valid code causing

FAIL: debug/tst-longjmp_chk2

The original check was

  altstack_sp + altstack_size - setjmp_sp > altstack_size

i.e. sp at setjmp was outside of the altstack range. Here we know that
longjmp is called from a signal handler on the altstack (SS_ONSTACK),
and that it jumps in the wrong direction (sp decreases), so the check
wants to ensure the jump goes to another stack.

The check is wrong when altstack_sp == setjmp_sp which can happen
when the altstack is a local buffer in the function that calls setjmp,
so the patch allows == too. This fixes bug 27709.

Note that the generic __longjmp_chk check seems to be different.
(it checks if longjmp was on the altstack but does not check setjmp,
so it would not catch incorrect longjmp use within the signal handler).
2021-04-12 14:28:07 +01:00
..
aarch64 aarch64: update libm test ulps 2021-04-08 08:24:30 +01:00
alpha
arc
arm arm: update libm test ulps 2021-04-08 09:55:33 +01:00
csky
generic fork.h: replace with register-atfork.h 2021-03-29 21:41:09 +02:00
gnu
hppa Update hppa libm-test-ulps 2021-04-06 18:55:58 +00:00
htl fork.h: replace with register-atfork.h 2021-03-29 21:41:09 +02:00
hurd
i386 i386: Update ulps 2021-04-05 10:02:15 -03:00
ia64 ia64: Update ulps 2021-04-05 10:11:09 -03:00
ieee754 Improve the accuracy of tgamma (BZ #26983) 2021-04-07 13:23:39 +02:00
m68k m68: Fix build after 9acda61d94 2021-04-06 15:10:31 -03:00
mach hurd: Export _hurd_libc_proc_init 2021-04-12 00:23:36 +02:00
microblaze
mips
nios2 Update Nios II libm-test-ulps. 2021-04-01 19:41:40 +00:00
nptl fork.h: replace with register-atfork.h 2021-03-29 21:41:09 +02:00
posix
powerpc powerpc: Update libm test ulps 2021-04-09 17:41:22 -03:00
pthread
riscv
s390 Fix the inaccuracy of j0f/j1f/y0f/y1f [BZ #14469, #14470, #14471, #14472] 2021-04-02 06:15:48 +02:00
sh
sparc Fix the inaccuracy of j0f/j1f/y0f/y1f [BZ #14469, #14470, #14471, #14472] 2021-04-02 06:15:48 +02:00
unix arm: Fix an incorrect check in ____longjmp_chk [BZ #27709] 2021-04-12 14:28:07 +01:00
wordsize-32
wordsize-64
x86 Move __isnanf128 to libc.so 2021-03-30 14:58:19 +05:30
x86_64 Improve the accuracy of tgamma (BZ #26983) 2021-04-07 13:23:39 +02:00