posix: Correctly enable/disable cancellation on Linux posix_spawn
commit706e6749de9667f3f3763743a294d28f895f4fa9
authorAdhemerval Zanella <adhemerval.zanella@linaro.org>
Wed, 14 Sep 2016 17:07:20 +0000 (14 14:07 -0300)
committerAdhemerval Zanella <adhemerval.zanella@linaro.org>
Tue, 20 Sep 2016 20:18:15 +0000 (20 17:18 -0300)
tree7494003744445d24f80373451027548d74607ff7
parentaea5c83461dac53b8619b7bf2ef1fb348ecb4ef1
posix: Correctly enable/disable cancellation on Linux posix_spawn

This patch correctly enable and disable asynchronous cancellation on
Linux posix_spawn.  Current code invert the logic by enabling and
disabling instead.  It also adds a new test to check if posix_spawn
is not a cancellation entrypoint.

Checked on x86_64, i686, powerpc64le, and aarch64.

* nptl/Makefile (tests): Add tst-exec5.
* nptl/tst-exec5.c: New file.
* sysdeps/unix/sysv/linux/spawni.c (__spawni): Correctly enable and disable
asynchronous cancellation.
ChangeLog
nptl/Makefile
nptl/tst-exec5.c [new file with mode: 0644]
sysdeps/unix/sysv/linux/spawni.c