From 38c2788499e5f13c438aab8075db47aa716e56f9 Mon Sep 17 00:00:00 2001 From: GNU Libc Maintainers Date: Sat, 8 Oct 2022 16:53:16 +0100 Subject: [PATCH] local-tst-eintr1-eagain 2012-06-06 Jonathan Nieder * nptl/tst-eintr1.c (tf1): Tolerate EAGAIN from pthread_create. Gbp-Pq: Topic any Gbp-Pq: Name local-tst-eintr1-eagain.diff --- nptl/tst-eintr1.c | 10 ++++++++++ 1 file changed, 10 insertions(+) diff --git a/nptl/tst-eintr1.c b/nptl/tst-eintr1.c index 4647cdb6d..e771d01e5 100644 --- a/nptl/tst-eintr1.c +++ b/nptl/tst-eintr1.c @@ -53,6 +53,16 @@ tf1 (void *arg) puts ("pthread_create returned EINTR"); exit (1); } + if (e == EAGAIN) + { + /* The kernel might not have processed the last few + pthread_join()s yet. Tolerate that, but record the + event in test output so attentive people reading + logs can notice if pthread_join() stops working + altogether. */ + write (STDOUT_FILENO, "!", 1); + continue; + } char buf[100]; printf ("tf1: pthread_create failed: %s\n", -- 2.30.2