From a6327f8a25b72f5edd3515aca82190046d18745b Mon Sep 17 00:00:00 2001 From: Anton Mitrofanov Date: Mon, 4 Feb 2019 21:46:12 +0300 Subject: [PATCH] Fix data race detected by ThreadSanitizer Bug report by Daniel Deptford. --- common/threadpool.c | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/common/threadpool.c b/common/threadpool.c index 7f98f778..4d36105b 100644 --- a/common/threadpool.c +++ b/common/threadpool.c @@ -34,7 +34,7 @@ typedef struct struct x264_threadpool_t { - int exit; + volatile int exit; int threads; x264_pthread_t *thread_handle; void (*init_func)(void *); -- 2.40.0