[PATCH 1/6] nptl: Fix tst-cancel7 and tst-cancelx7 race condition (BZ #14232)
Florian Weimer
fweimer@redhat.com
Fri Jun 11 15:10:56 GMT 2021
* Adhemerval Zanella:
> On 11/06/2021 12:02, Florian Weimer wrote:
>> * Adhemerval Zanella via Libc-alpha:
>>
>>> +static const char sem_name[] = "/tst-cancel7-sem";
>>
>> I don't think this is valid, it will break with concurrent execution of
>> the test suite from different build trees.
>>
>> Maybe you could use support_shared_allocate and sem_init with a
>> process-shared semaphore?
>
> Indeed I did not take this in consideration. But support_shared_allocate is
> similar to the unnamed semaphore and the test will use a system() to spawn
> the test process. So support_shared_allocate does not really help here.
Hmm. I guess you could use a mapped file created with create_temp_file,
and pass the name on the command line.
Thanks,
Florian
More information about the Libc-alpha
mailing list