From 8f7c69ede20116a533512bff9cd5b23cfbbd0293 Mon Sep 17 00:00:00 2001 From: Stanislaw Halik Date: Fri, 5 Jul 2019 11:20:14 +0200 Subject: proto/wine: fix qprocess warning --- proto-wine/ftnoir_protocol_wine.cpp | 9 +++++++-- 1 file changed, 7 insertions(+), 2 deletions(-) (limited to 'proto-wine') diff --git a/proto-wine/ftnoir_protocol_wine.cpp b/proto-wine/ftnoir_protocol_wine.cpp index edeb8ce4..1b259fd4 100644 --- a/proto-wine/ftnoir_protocol_wine.cpp +++ b/proto-wine/ftnoir_protocol_wine.cpp @@ -18,11 +18,16 @@ wine::wine() = default; wine::~wine() { #ifndef OTR_WINE_NO_WRAPPER + bool exit = false; if (shm) { shm->stop = true; - wrapper.waitForFinished(100); + exit = wrapper.waitForFinished(100); + } + if (!exit) + { + wrapper.kill(); + wrapper.waitForFinished(-1); } - wrapper.kill(); #endif //shm_unlink("/" WINE_SHM_NAME); } -- cgit v1.2.3