summaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
authorLuboš Doležel <lubos@dolezel.info>2016-01-07 10:07:18 +0100
committerLuboš Doležel <lubos@dolezel.info>2016-01-07 10:07:18 +0100
commit42678b3346f05c3cce3915989b1057785bde989e (patch)
tree6fd43f69a7e599783cdbce44ecf8bb4e6ef3d6c4
parentd069536223fee363f9237d47e47793cfdccdf8d6 (diff)
parent69ed9203aeab319f8529a77945dd09c983538fa7 (diff)
downloadtwinkle-42678b3346f05c3cce3915989b1057785bde989e.tar
twinkle-42678b3346f05c3cce3915989b1057785bde989e.tar.gz
twinkle-42678b3346f05c3cce3915989b1057785bde989e.tar.lz
twinkle-42678b3346f05c3cce3915989b1057785bde989e.tar.xz
twinkle-42678b3346f05c3cce3915989b1057785bde989e.zip
Merge pull request #51 from fbriere/logview-race-condition
Fix race condition over deletion of sema_logview
-rw-r--r--src/log.cpp2
1 files changed, 1 insertions, 1 deletions
diff --git a/src/log.cpp b/src/log.cpp
index 136afd3..1f27e63 100644
--- a/src/log.cpp
+++ b/src/log.cpp
@@ -350,11 +350,11 @@ void t_log::enable_inform_user(bool on) {
if (!thr_logview) {
thr_logview = new t_thread(main_logview, NULL);
- thr_logview->detach();
}
} else {
if (thr_logview) {
thr_logview->cancel();
+ thr_logview->join();
delete thr_logview;
thr_logview = NULL;
}