From eb6b4f4b15cd17f803efd9ad09ce5822ae0cdc76 Mon Sep 17 00:00:00 2001 From: Robin Gareus Date: Fri, 23 Oct 2015 23:27:15 +0200 Subject: [PATCH] fix crash on SystemExec::Terminate if Terminated() connects in the same thread and deletes the class itself the closure in interposer_thread() can fail. --- libs/pbd/system_exec.cc | 2 ++ 1 file changed, 2 insertions(+) diff --git a/libs/pbd/system_exec.cc b/libs/pbd/system_exec.cc index d92987bf21..02e4ddcd85 100644 --- a/libs/pbd/system_exec.cc +++ b/libs/pbd/system_exec.cc @@ -530,6 +530,7 @@ SystemExec::output_interposer() ReadStdout(data, bytesRead);/* EMIT SIGNAL */ } Terminated();/* EMIT SIGNAL */ + pthread_exit(0); } void @@ -896,6 +897,7 @@ SystemExec::output_interposer() ReadStdout(rv, r);/* EMIT SIGNAL */ } Terminated();/* EMIT SIGNAL */ + pthread_exit(0); } void