glibc/stdlib
Carlos O'Donell c92d40c0bc Bug 18125: Call exit after last linked context.
There appears to be a discrepancy among the implementations
of setcontext with regards to the function called once the last
linked-to context has finished executing via setcontext.

The POSIX standard says:
~~~
If the uc_link member of the ucontext_t structure pointed to by
the ucp argument is equal to 0, then this context is the main
context, and the thread will exit when this context returns.
~~~

It says "exit" not "exit immediately" nor "exit without running
functions registered with atexit or on_exit."

Therefore the AArch64, ARM, hppa and NIOS II implementations are
wrong and no test detects it.

It is questionable if this should even be fixed or just documented
that the above 4 targets are wrong. The functions are deprecated
and nobody should be using them, but at the same time it silly to
have cross-target differences that make it hard to port old
applications from say x86_64 to AArch64.

Therefore I will ix the 4 arches, and checkin a regression
test to prevent it from changing again.

https://sourceware.org/ml/libc-alpha/2015-03/msg00720.html
2015-05-08 11:29:38 -04:00
..
bits Update copyright dates with scripts/update-copyrights. 2015-01-02 16:29:47 +00:00
sys Update. 2002-07-20 01:14:41 +00:00
a64l.c Update copyright dates with scripts/update-copyrights. 2015-01-02 16:29:47 +00:00
abort.c Update copyright dates with scripts/update-copyrights. 2015-01-02 16:29:47 +00:00
abs.c Update copyright dates with scripts/update-copyrights. 2015-01-02 16:29:47 +00:00
add_n.c Update copyright dates with scripts/update-copyrights. 2015-01-02 16:29:47 +00:00
addmul_1.c Update copyright dates with scripts/update-copyrights. 2015-01-02 16:29:47 +00:00
alloca.h Update copyright dates with scripts/update-copyrights. 2015-01-02 16:29:47 +00:00
at_quick_exit.c Update copyright dates with scripts/update-copyrights. 2015-01-02 16:29:47 +00:00
atexit.c Update copyright dates with scripts/update-copyrights. 2015-01-02 16:29:47 +00:00
atof.c Update copyright dates with scripts/update-copyrights. 2015-01-02 16:29:47 +00:00
atoi.c Update copyright dates with scripts/update-copyrights. 2015-01-02 16:29:47 +00:00
atol.c Update copyright dates with scripts/update-copyrights. 2015-01-02 16:29:47 +00:00
atoll.c Update copyright dates with scripts/update-copyrights. 2015-01-02 16:29:47 +00:00
bsearch.c Update copyright dates with scripts/update-copyrights. 2015-01-02 16:29:47 +00:00
bug-fmtmsg1.c Fix locking problem in fmtmsg 2012-01-16 09:03:20 -05:00
bug-getcontext.c Fix bug-getcontext test 2012-07-16 18:46:40 +02:00
bug-strtod2.c [BZ #1230] 2005-09-28 06:09:24 +00:00
bug-strtod.c Update copyright dates with scripts/update-copyrights. 2015-01-02 16:29:47 +00:00
canonicalize.c Update copyright dates with scripts/update-copyrights. 2015-01-02 16:29:47 +00:00
cmp.c Update copyright dates with scripts/update-copyrights. 2015-01-02 16:29:47 +00:00
cxa_at_quick_exit.c Update copyright dates with scripts/update-copyrights. 2015-01-02 16:29:47 +00:00
cxa_atexit.c Update copyright dates with scripts/update-copyrights. 2015-01-02 16:29:47 +00:00
cxa_finalize.c Update copyright dates with scripts/update-copyrights. 2015-01-02 16:29:47 +00:00
cxa_thread_atexit_impl.c Update copyright dates with scripts/update-copyrights. 2015-01-02 16:29:47 +00:00
dbl2mpn.c Update copyright dates with scripts/update-copyrights. 2015-01-02 16:29:47 +00:00
Depend [BZ #1230] 2005-09-28 06:09:24 +00:00
div.c Update copyright dates with scripts/update-copyrights. 2015-01-02 16:29:47 +00:00
divmod_1.c Update copyright dates with scripts/update-copyrights. 2015-01-02 16:29:47 +00:00
divrem.c Update copyright dates with scripts/update-copyrights. 2015-01-02 16:29:47 +00:00
drand48_r.c Update copyright dates with scripts/update-copyrights. 2015-01-02 16:29:47 +00:00
drand48-iter.c Update copyright dates with scripts/update-copyrights. 2015-01-02 16:29:47 +00:00
drand48.c Update copyright dates with scripts/update-copyrights. 2015-01-02 16:29:47 +00:00
erand48_r.c Update copyright dates with scripts/update-copyrights. 2015-01-02 16:29:47 +00:00
erand48.c Update copyright dates with scripts/update-copyrights. 2015-01-02 16:29:47 +00:00
errno.h Update copyright dates with scripts/update-copyrights. 2015-01-02 16:29:47 +00:00
exit.c Update copyright dates with scripts/update-copyrights. 2015-01-02 16:29:47 +00:00
exit.h Update copyright dates with scripts/update-copyrights. 2015-01-02 16:29:47 +00:00
fmtmsg.c Update copyright dates with scripts/update-copyrights. 2015-01-02 16:29:47 +00:00
fmtmsg.h Update copyright dates with scripts/update-copyrights. 2015-01-02 16:29:47 +00:00
fpioconst.c Update copyright dates with scripts/update-copyrights. 2015-01-02 16:29:47 +00:00
fpioconst.h Update copyright dates with scripts/update-copyrights. 2015-01-02 16:29:47 +00:00
gen-fpioconst.c Update copyright dates with scripts/update-copyrights. 2015-01-02 16:29:47 +00:00
gen-tst-strtod-round.c Update copyright dates with scripts/update-copyrights. 2015-01-02 16:29:47 +00:00
getcontext.c Update copyright dates with scripts/update-copyrights. 2015-01-02 16:29:47 +00:00
getenv.c Update copyright dates with scripts/update-copyrights. 2015-01-02 16:29:47 +00:00
getsubopt.c Update copyright dates with scripts/update-copyrights. 2015-01-02 16:29:47 +00:00
gmp-impl.h Update copyright dates with scripts/update-copyrights. 2015-01-02 16:29:47 +00:00
gmp.h Update copyright dates with scripts/update-copyrights. 2015-01-02 16:29:47 +00:00
grouping.c Update copyright dates with scripts/update-copyrights. 2015-01-02 16:29:47 +00:00
grouping.h Update copyright dates with scripts/update-copyrights. 2015-01-02 16:29:47 +00:00
groupingwc.c Update. 2003-06-11 23:22:36 +00:00
inlines.c Moved to csu/errno-loc.c. 2005-12-14 15:06:39 +00:00
isomac.c Update copyright dates with scripts/update-copyrights. 2015-01-02 16:29:47 +00:00
jrand48_r.c Update copyright dates with scripts/update-copyrights. 2015-01-02 16:29:47 +00:00
jrand48.c Update copyright dates with scripts/update-copyrights. 2015-01-02 16:29:47 +00:00
l64a.c Update copyright dates with scripts/update-copyrights. 2015-01-02 16:29:47 +00:00
labs.c Update copyright dates with scripts/update-copyrights. 2015-01-02 16:29:47 +00:00
lcong48_r.c Update copyright dates with scripts/update-copyrights. 2015-01-02 16:29:47 +00:00
lcong48.c Update copyright dates with scripts/update-copyrights. 2015-01-02 16:29:47 +00:00
ldbl2mpn.c Moved to csu/errno-loc.c. 2005-12-14 15:06:39 +00:00
ldiv.c Update copyright dates with scripts/update-copyrights. 2015-01-02 16:29:47 +00:00
llabs.c Update copyright dates with scripts/update-copyrights. 2015-01-02 16:29:47 +00:00
lldiv.c Update copyright dates with scripts/update-copyrights. 2015-01-02 16:29:47 +00:00
longlong.h Update copyright dates with scripts/update-copyrights. 2015-01-02 16:29:47 +00:00
lrand48_r.c Update copyright dates with scripts/update-copyrights. 2015-01-02 16:29:47 +00:00
lrand48.c Update copyright dates with scripts/update-copyrights. 2015-01-02 16:29:47 +00:00
lshift.c Update copyright dates with scripts/update-copyrights. 2015-01-02 16:29:47 +00:00
makecontext.c Update copyright dates with scripts/update-copyrights. 2015-01-02 16:29:47 +00:00
Makefile Bug 18125: Call exit after last linked context. 2015-05-08 11:29:38 -04:00
mblen.c Update copyright dates with scripts/update-copyrights. 2015-01-02 16:29:47 +00:00
mbstowcs.c Update copyright dates with scripts/update-copyrights. 2015-01-02 16:29:47 +00:00
mbtowc.c Update copyright dates with scripts/update-copyrights. 2015-01-02 16:29:47 +00:00
mod_1.c Update copyright dates with scripts/update-copyrights. 2015-01-02 16:29:47 +00:00
monetary.h Update copyright dates with scripts/update-copyrights. 2015-01-02 16:29:47 +00:00
mp_clz_tab.c Update copyright dates with scripts/update-copyrights. 2015-01-02 16:29:47 +00:00
mpn2dbl.c Update copyright dates with scripts/update-copyrights. 2015-01-02 16:29:47 +00:00
mpn2flt.c Update copyright dates with scripts/update-copyrights. 2015-01-02 16:29:47 +00:00
mpn2ldbl.c Moved to csu/errno-loc.c. 2005-12-14 15:06:39 +00:00
mrand48_r.c Update copyright dates with scripts/update-copyrights. 2015-01-02 16:29:47 +00:00
mrand48.c Update copyright dates with scripts/update-copyrights. 2015-01-02 16:29:47 +00:00
msort.c Update copyright dates with scripts/update-copyrights. 2015-01-02 16:29:47 +00:00
mul_1.c Update copyright dates with scripts/update-copyrights. 2015-01-02 16:29:47 +00:00
mul_n.c Update copyright dates with scripts/update-copyrights. 2015-01-02 16:29:47 +00:00
mul.c Update copyright dates with scripts/update-copyrights. 2015-01-02 16:29:47 +00:00
nrand48_r.c Update copyright dates with scripts/update-copyrights. 2015-01-02 16:29:47 +00:00
nrand48.c Update copyright dates with scripts/update-copyrights. 2015-01-02 16:29:47 +00:00
old_atexit.c Update. 2004-03-10 09:29:17 +00:00
on_exit.c Update copyright dates with scripts/update-copyrights. 2015-01-02 16:29:47 +00:00
putenv.c Update copyright dates with scripts/update-copyrights. 2015-01-02 16:29:47 +00:00
qsort.c Update copyright dates with scripts/update-copyrights. 2015-01-02 16:29:47 +00:00
quick_exit.c Update copyright dates with scripts/update-copyrights. 2015-01-02 16:29:47 +00:00
rand_r.c Update copyright dates with scripts/update-copyrights. 2015-01-02 16:29:47 +00:00
rand.c Update copyright dates with scripts/update-copyrights. 2015-01-02 16:29:47 +00:00
random_r.c Update copyright dates with scripts/update-copyrights. 2015-01-02 16:29:47 +00:00
random.c Update copyright dates with scripts/update-copyrights. 2015-01-02 16:29:47 +00:00
rpmatch.c Update copyright dates with scripts/update-copyrights. 2015-01-02 16:29:47 +00:00
rshift.c Update copyright dates with scripts/update-copyrights. 2015-01-02 16:29:47 +00:00
secure-getenv.c Update copyright dates with scripts/update-copyrights. 2015-01-02 16:29:47 +00:00
seed48_r.c Update copyright dates with scripts/update-copyrights. 2015-01-02 16:29:47 +00:00
seed48.c Update copyright dates with scripts/update-copyrights. 2015-01-02 16:29:47 +00:00
setcontext.c Update copyright dates with scripts/update-copyrights. 2015-01-02 16:29:47 +00:00
setenv.c Better fix for setenv (..., NULL, ...) 2015-04-19 01:07:31 -07:00
srand48_r.c Update copyright dates with scripts/update-copyrights. 2015-01-02 16:29:47 +00:00
srand48.c Update copyright dates with scripts/update-copyrights. 2015-01-02 16:29:47 +00:00
stdlib.h Update copyright dates with scripts/update-copyrights. 2015-01-02 16:29:47 +00:00
strfmon_l.c Update copyright dates with scripts/update-copyrights. 2015-01-02 16:29:47 +00:00
strfmon.c Update copyright dates with scripts/update-copyrights. 2015-01-02 16:29:47 +00:00
strtod_l.c Fix strtof decimal rounding close to half least subnormal (bug 18247). 2015-04-10 20:45:30 +00:00
strtod.c Update copyright dates with scripts/update-copyrights. 2015-01-02 16:29:47 +00:00
strtof_l.c Update copyright dates with scripts/update-copyrights. 2015-01-02 16:29:47 +00:00
strtof.c Update copyright dates with scripts/update-copyrights. 2015-01-02 16:29:47 +00:00
strtoimax.c Moved to csu/errno-loc.c. 2005-12-14 15:06:39 +00:00
strtol_l.c Update copyright dates with scripts/update-copyrights. 2015-01-02 16:29:47 +00:00
strtol.c Update copyright dates with scripts/update-copyrights. 2015-01-02 16:29:47 +00:00
strtold_l.c Update copyright dates with scripts/update-copyrights. 2015-01-02 16:29:47 +00:00
strtold.c Update copyright dates with scripts/update-copyrights. 2015-01-02 16:29:47 +00:00
strtoll_l.c Update copyright dates with scripts/update-copyrights. 2015-01-02 16:29:47 +00:00
strtoll.c Update copyright dates with scripts/update-copyrights. 2015-01-02 16:29:47 +00:00
strtoul_l.c Update copyright dates with scripts/update-copyrights. 2015-01-02 16:29:47 +00:00
strtoul.c Update copyright dates with scripts/update-copyrights. 2015-01-02 16:29:47 +00:00
strtoull_l.c Update copyright dates with scripts/update-copyrights. 2015-01-02 16:29:47 +00:00
strtoull.c Update copyright dates with scripts/update-copyrights. 2015-01-02 16:29:47 +00:00
strtoumax.c Moved to csu/errno-loc.c. 2005-12-14 15:06:39 +00:00
sub_n.c Update copyright dates with scripts/update-copyrights. 2015-01-02 16:29:47 +00:00
submul_1.c Update copyright dates with scripts/update-copyrights. 2015-01-02 16:29:47 +00:00
swapcontext.c Update copyright dates with scripts/update-copyrights. 2015-01-02 16:29:47 +00:00
system.c Update copyright dates with scripts/update-copyrights. 2015-01-02 16:29:47 +00:00
tens_in_limb.c * stdlib/Makefile (aux): Add tens_in_limb. 2008-03-08 04:18:31 +00:00
test-a64l.c Update copyright dates with scripts/update-copyrights. 2015-01-02 16:29:47 +00:00
test-canon2.c Update copyright dates with scripts/update-copyrights. 2015-01-02 16:29:47 +00:00
test-canon.c Update copyright dates with scripts/update-copyrights. 2015-01-02 16:29:47 +00:00
testdiv.c Update copyright dates with scripts/update-copyrights. 2015-01-02 16:29:47 +00:00
testdiv.input initial import 1995-02-18 01:27:10 +00:00
testmb2.c Update. 2004-02-23 23:30:12 +00:00
testmb.c Update. 1998-04-15 17:02:23 +00:00
testrand.c Update copyright dates with scripts/update-copyrights. 2015-01-02 16:29:47 +00:00
testsort.c Update. 2000-12-05 08:17:58 +00:00
tst-atof1.c * stdlib/strtod_l.c (____STRTOF_INTERNAL): Parse thousand 2006-12-11 21:43:56 +00:00
tst-atof2.c [BZ #3673] 2006-12-10 01:11:45 +00:00
tst-bsearch.c Update copyright dates with scripts/update-copyrights. 2015-01-02 16:29:47 +00:00
tst-environ.c Update copyright dates with scripts/update-copyrights. 2015-01-02 16:29:47 +00:00
tst-fmtmsg.c Modify several tests to use test-skeleton.c 2014-11-05 15:24:08 +05:30
tst-fmtmsg.sh Update copyright dates with scripts/update-copyrights. 2015-01-02 16:29:47 +00:00
tst-limits.c Fix a couple of -Wundef warnings. 2014-12-29 23:14:38 -05:00
tst-makecontext2.c Update copyright dates with scripts/update-copyrights. 2015-01-02 16:29:47 +00:00
tst-makecontext3.c Update copyright dates with scripts/update-copyrights. 2015-01-02 16:29:47 +00:00
tst-makecontext.c Update copyright dates with scripts/update-copyrights. 2015-01-02 16:29:47 +00:00
tst-putenv.c Update. 2005-01-04 07:48:13 +00:00
tst-putenvmod.c Update. 2005-01-04 07:48:13 +00:00
tst-qsort2.c stdlib/tst-qsort2.c: Fix off-by-one argc interpretation error 2014-06-20 21:29:33 +01:00
tst-qsort.c Update. 2003-09-17 18:23:49 +00:00
tst-rand48-2.c Modify several tests to use test-skeleton.c 2014-11-05 15:24:08 +05:30
tst-rand48.c Modify several tests to use test-skeleton.c 2014-11-05 15:24:08 +05:30
tst-random2.c Update copyright dates with scripts/update-copyrights. 2015-01-02 16:29:47 +00:00
tst-random.c Modify several tests to use test-skeleton.c 2014-11-05 15:24:08 +05:30
tst-secure-getenv.c Update copyright dates with scripts/update-copyrights. 2015-01-02 16:29:47 +00:00
tst-setcontext2.c S/390: Fix setcontext/swapcontext which are not restoring sigmask. 2015-03-12 11:08:11 +01:00
tst-setcontext3.c Bug 18125: Call exit after last linked context. 2015-05-08 11:29:38 -04:00
tst-setcontext3.sh Bug 18125: Call exit after last linked context. 2015-05-08 11:29:38 -04:00
tst-setcontext.c Update copyright dates with scripts/update-copyrights. 2015-01-02 16:29:47 +00:00
tst-strtod2.c * stdlib/tst-strtod2.c (do_test): Use %tu in fmt string for ptrdiff_t 2007-08-01 03:44:35 +00:00
tst-strtod3.c * stdlib/strtod_l.c (____STRTOF_INTERNAL): Parse thousand 2006-12-11 21:43:56 +00:00
tst-strtod4.c Include errno.h. Change main() to do_test(). Define TEST_FUNCTION. Include test-skeleton.c. (do_test): Check errno and exit(0) if ENOSYS. 2007-01-11 21:51:00 +00:00
tst-strtod5.c * stdlib/strtod_l.c (____STRTOF_INTERNAL): Properly handle -0. 2007-08-03 16:45:47 +00:00
tst-strtod6.c [BZ #15522] strtod ("nan(N)") returning a sNaN in some cases 2013-08-29 12:22:10 +02:00
tst-strtod-overflow.c Update copyright dates with scripts/update-copyrights. 2015-01-02 16:29:47 +00:00
tst-strtod-round-data Fix strtof decimal rounding close to half least subnormal (bug 18247). 2015-04-10 20:45:30 +00:00
tst-strtod-round.c Fix strtof decimal rounding close to half least subnormal (bug 18247). 2015-04-10 20:45:30 +00:00
tst-strtod-underflow.c Update copyright dates with scripts/update-copyrights. 2015-01-02 16:29:47 +00:00
tst-strtod.c Update copyright dates with scripts/update-copyrights. 2015-01-02 16:29:47 +00:00
tst-strtol.c Modify several tests to use test-skeleton.c 2014-11-05 15:24:08 +05:30
tst-strtoll.c Modify several tests to use test-skeleton.c 2014-11-05 15:24:08 +05:30
tst-system.c Update copyright dates with scripts/update-copyrights. 2015-01-02 16:29:47 +00:00
tst-tininess.c Update copyright dates with scripts/update-copyrights. 2015-01-02 16:29:47 +00:00
tst-tls-atexit-lib.c Update copyright dates with scripts/update-copyrights. 2015-01-02 16:29:47 +00:00
tst-tls-atexit.c Update copyright dates with scripts/update-copyrights. 2015-01-02 16:29:47 +00:00
tst-unsetenv1.c * stdlib/Makefile (tests): Add tst-unsetenv1. 2008-12-02 02:27:43 +00:00
tst-xpg-basename.c Update copyright dates with scripts/update-copyrights. 2015-01-02 16:29:47 +00:00
ucontext.h Update copyright dates with scripts/update-copyrights. 2015-01-02 16:29:47 +00:00
udiv_qrnnd.c Moved to csu/errno-loc.c. 2005-12-14 15:06:39 +00:00
Versions C++11 thread_local destructors support 2013-02-18 19:08:21 +05:30
wcstoimax.c Moved to csu/errno-loc.c. 2005-12-14 15:06:39 +00:00
wcstombs.c Update copyright dates with scripts/update-copyrights. 2015-01-02 16:29:47 +00:00
wcstoumax.c Moved to csu/errno-loc.c. 2005-12-14 15:06:39 +00:00
wctomb.c Update copyright dates with scripts/update-copyrights. 2015-01-02 16:29:47 +00:00
xpg_basename.c Update copyright dates with scripts/update-copyrights. 2015-01-02 16:29:47 +00:00