nptl: Fix tst-cancel7 and tst-cancelx7 race condition (BZ #14232)
authorAdhemerval Zanella <adhemerval.zanella@linaro.org>
Fri, 4 Jun 2021 12:49:30 +0000 (09:49 -0300)
committerAdhemerval Zanella <adhemerval.zanella@linaro.org>
Thu, 26 Aug 2021 20:13:47 +0000 (17:13 -0300)
commit6f4973c1a2449438840a838732052e029fbea737
treea30e22c0310ec6752f7f6ab9835f03080ee4cf80
parent6b20880b22d1d0fce7e9f506baa6fe2d5c7fcfdc
nptl: Fix tst-cancel7 and tst-cancelx7 race condition (BZ #14232)

A mapped temporary file and a semaphore is used to synchronize the
pid information on the created file, the semaphore is updated once
the file contents is flushed.

Checked on x86_64-linux-gnu.

Reviewed-by: Florian Weimer <fweimer@redhat.com>
nptl/tst-cancel7.c