diff --git a/src/Application.cpp b/src/Application.cpp index 4676359f..6d7e0f63 100644 --- a/src/Application.cpp +++ b/src/Application.cpp @@ -23,6 +23,7 @@ namespace Bloom : arguments(std::move(arguments)) , qtApplication( ( + Thread::blockAllSignals(), QCoreApplication::setAttribute(Qt::AA_ShareOpenGLContexts, true), #ifndef BLOOM_DEBUG_BUILD QCoreApplication::addLibraryPath(QString::fromStdString(Services::PathService::applicationDirPath() + "/plugins")), @@ -137,7 +138,6 @@ namespace Bloom Logger::debug("Bloom version: " + Application::VERSION.toString()); - this->blockAllSignals(); this->startSignalHandler(); Logger::info("Selected environment: \"" + this->selectedEnvironmentName + "\""); diff --git a/src/Helpers/Thread.hpp b/src/Helpers/Thread.hpp index 9fa2c10b..24241753 100644 --- a/src/Helpers/Thread.hpp +++ b/src/Helpers/Thread.hpp @@ -38,7 +38,7 @@ namespace Bloom /** * Disables signal interrupts on current thread. */ - void blockAllSignals() { + static void blockAllSignals() { sigset_t set = {}; sigfillset(&set); sigprocmask(SIG_SETMASK, &set, NULL);