X-Git-Url: https://git.stg.codes/stg.git/blobdiff_plain/a500fb72810060e52d87ad2c2e4691531f0bcc5a..38f134e6a96c08fdd7d4ed07ca3550e8434d56e9:/projects/stargazer/plugins/other/rscript/rscript.cpp?ds=sidebyside

diff --git a/projects/stargazer/plugins/other/rscript/rscript.cpp b/projects/stargazer/plugins/other/rscript/rscript.cpp
index 8b0e2054..95699e10 100644
--- a/projects/stargazer/plugins/other/rscript/rscript.cpp
+++ b/projects/stargazer/plugins/other/rscript/rscript.cpp
@@ -265,6 +265,8 @@ if (isRunning)
     logger("Cannot stop thread.");
     m_thread.detach();
     }
+else
+    m_thread.join();
 
 return 0;
 }