diff options
Diffstat (limited to 'src/corelib/thread/qthread.cpp')
| -rw-r--r-- | src/corelib/thread/qthread.cpp | 8 |
1 files changed, 2 insertions, 6 deletions
diff --git a/src/corelib/thread/qthread.cpp b/src/corelib/thread/qthread.cpp index 14209d8d8cd..f689ad4d213 100644 --- a/src/corelib/thread/qthread.cpp +++ b/src/corelib/thread/qthread.cpp @@ -883,16 +883,12 @@ bool QThread::isInterruptionRequested() const Note: don't try to deliver events from the started() signal. */ -static void setThreadDoesNotRequireCoreApplication() -{ - QThreadData::current()->requiresCoreApplication = false; -} - QDaemonThread::QDaemonThread(QObject *parent) : QThread(parent) { // QThread::started() is emitted from the thread we start - connect(this, &QThread::started, setThreadDoesNotRequireCoreApplication); + connect(this, &QThread::started, + [](){ QThreadData::current()->requiresCoreApplication = false; }); } QDaemonThread::~QDaemonThread() |
