aboutsummaryrefslogtreecommitdiff
path: root/cddl/contrib/opensolaris
diff options
context:
space:
mode:
authorAlex Richardson <arichardson@FreeBSD.org>2020-08-06 20:44:40 +0000
committerAlex Richardson <arichardson@FreeBSD.org>2020-08-06 20:44:40 +0000
commit5ac01ce026aa871e24065f931b5b5c36024c96f9 (patch)
treeadbe56cca88a71404738cffdceccd3cfff160310 /cddl/contrib/opensolaris
parentdd7660e5bdfb6510c993f066723b1669c14ceec6 (diff)
downloadsrc-5ac01ce026aa871e24065f931b5b5c36024c96f9.tar.gz
src-5ac01ce026aa871e24065f931b5b5c36024c96f9.zip
ctfmerge: Fix missing pthread_cond_init()
This does not appear to matter on FreeBSD or Linux, but when building an amd64 kernel on macOS I was seeing infinite loops in ctfmerge. It turns out the loop in wip_save_work() was looping forever due to pthread_cond_wait() always returning -EINVAL. Reviewed By: markj, brooks Differential Revision: https://reviews.freebsd.org/D25973
Notes
Notes: svn path=/head/; revision=363991
Diffstat (limited to 'cddl/contrib/opensolaris')
-rw-r--r--cddl/contrib/opensolaris/tools/ctf/cvt/ctfmerge.c1
1 files changed, 1 insertions, 0 deletions
diff --git a/cddl/contrib/opensolaris/tools/ctf/cvt/ctfmerge.c b/cddl/contrib/opensolaris/tools/ctf/cvt/ctfmerge.c
index a3d05ad20b28..ddb5f388ca98 100644
--- a/cddl/contrib/opensolaris/tools/ctf/cvt/ctfmerge.c
+++ b/cddl/contrib/opensolaris/tools/ctf/cvt/ctfmerge.c
@@ -665,6 +665,7 @@ wq_init(workqueue_t *wq, int nfiles)
for (i = 0; i < nslots; i++) {
pthread_mutex_init(&wq->wq_wip[i].wip_lock, NULL);
+ pthread_cond_init(&wq->wq_wip[i].wip_cv, NULL);
wq->wq_wip[i].wip_batchid = wq->wq_next_batchid++;
}