diff options
author | dchagin <dchagin@FreeBSD.org> | 2015-05-24 14:54:12 +0000 |
---|---|---|
committer | dchagin <dchagin@FreeBSD.org> | 2015-05-24 14:54:12 +0000 |
commit | e2a838697261bbf29d13ae085533517d7b889436 (patch) | |
tree | 6c5e3525490b2cda7422bdd5541b19892a261214 | |
parent | 50155e11ccf67feb9f37fa2e123e63bf34e9c64c (diff) | |
download | FreeBSD-src-e2a838697261bbf29d13ae085533517d7b889436.zip FreeBSD-src-e2a838697261bbf29d13ae085533517d7b889436.tar.gz |
pthread_join() caller do futex_wait on child_clear_tid. As a results
of multiple simultaneous calls to pthread_join() specifying the same
target thread are undefined wake up the one thread.
Differential Revision: https://reviews.freebsd.org/D1040
-rw-r--r-- | sys/compat/linux/linux_emul.c | 2 |
1 files changed, 1 insertions, 1 deletions
diff --git a/sys/compat/linux/linux_emul.c b/sys/compat/linux/linux_emul.c index 6d88d7b..502e936 100644 --- a/sys/compat/linux/linux_emul.c +++ b/sys/compat/linux/linux_emul.c @@ -270,7 +270,7 @@ linux_thread_detach(struct thread *td) cup.uaddr = child_clear_tid; cup.op = LINUX_FUTEX_WAKE; - cup.val = 0x7fffffff; /* Awake everyone */ + cup.val = 1; /* wake one */ cup.timeout = NULL; cup.uaddr2 = NULL; cup.val3 = 0; |