From 10aeea73b434bf6b06d5ebb1631ac53b0b1076bb Mon Sep 17 00:00:00 2001 From: Josh Cartwright Date: Mon, 31 Aug 2015 11:35:34 -0500 Subject: cyclictest: fail if use_fifo && thread creation failed Signed-off-by: Josh Cartwright Signed-off-by: John Kacur --- src/cyclictest/cyclictest.c | 5 ++++- 1 file changed, 4 insertions(+), 1 deletion(-) diff --git a/src/cyclictest/cyclictest.c b/src/cyclictest/cyclictest.c index 5d83bb1..7346a32 100644 --- a/src/cyclictest/cyclictest.c +++ b/src/cyclictest/cyclictest.c @@ -2058,8 +2058,11 @@ int main(int argc, char **argv) fatal("failed to create thread %d: %s\n", i, strerror(status)); } - if (use_fifo) + if (use_fifo) { status = pthread_create(&fifo_threadid, NULL, fifothread, NULL); + if (status) + fatal("failed to create fifo thread: %s\n", strerror(status)); + } while (!shutdown) { char lavg[256]; -- cgit 1.2.3-korg