From 04794f3e7e9a8f61519b7d8bb5ad864431d3e488 Mon Sep 17 00:00:00 2001 From: Samuel Thibault Date: Wed, 4 May 2016 15:51:19 +0200 Subject: Revert "aio: fix newp->running data race" This reverts commit fd67a9cf7b733da082e4b6a5f25c19ea7921b4cd. --- sysdeps/pthread/aio_misc.c | 8 +++----- 1 file changed, 3 insertions(+), 5 deletions(-) (limited to 'sysdeps') diff --git a/sysdeps/pthread/aio_misc.c b/sysdeps/pthread/aio_misc.c index faf139d..f55570d 100644 --- a/sysdeps/pthread/aio_misc.c +++ b/sysdeps/pthread/aio_misc.c @@ -453,11 +453,7 @@ __aio_enqueue_request (aiocb_union *aiocbp, int operation) result = 0; } } - else - newp->running = running; } - else - newp->running = running; /* Enqueue the request in the run queue if it is not yet running. */ if (running == yes && result == 0) @@ -470,7 +466,9 @@ __aio_enqueue_request (aiocb_union *aiocbp, int operation) pthread_cond_signal (&__aio_new_request_notification); } - if (result != 0) + if (result == 0) + newp->running = running; + else { /* Something went wrong. */ __aio_free_request (newp); -- cgit v1.1