From ae680a5bdcb244bcaed9c74efb82ba5e18168e24 Mon Sep 17 00:00:00 2001 From: Sebastian Messmer Date: Sat, 16 Mar 2019 17:59:55 -0700 Subject: [PATCH] Stop FuseThread without using signals --- test/fspp/testutils/FuseThread.cpp | 4 +--- 1 file changed, 1 insertion(+), 3 deletions(-) diff --git a/test/fspp/testutils/FuseThread.cpp b/test/fspp/testutils/FuseThread.cpp index b73df2f4..277a2dac 100644 --- a/test/fspp/testutils/FuseThread.cpp +++ b/test/fspp/testutils/FuseThread.cpp @@ -29,9 +29,7 @@ void FuseThread::start(const bf::path &mountDir, const vector &fuseOptio } void FuseThread::stop() { - if (0 != pthread_kill(_child.native_handle(), SIGINT)) { - throw std::runtime_error("Error sending stop signal"); - } + _fuse->stop(); bool thread_stopped = _child.try_join_for(seconds(10)); ASSERT(thread_stopped, "FuseThread could not be stopped"); //Wait until it is properly shutdown (busy waiting is simple and doesn't hurt much here)