aboutsummaryrefslogtreecommitdiffstats
path: root/src/qml/debugger
diff options
context:
space:
mode:
authorUlf Hermann <ulf.hermann@digia.com>2014-01-29 17:30:14 +0100
committerThe Qt Project <gerrit-noreply@qt-project.org>2014-01-29 18:30:34 +0100
commit13683d4ebc16f9cf22c0c2c67ee2f0acfc8c8fbc (patch)
tree5a81423ee444abc574fd0e3aa95f66bb129940d6 /src/qml/debugger
parent0c7ef1b350dd826334370a70e1d3b6b47e08a731 (diff)
Allow debug plugin registrations from other threads than main GUI
There's no real reason to disallow that. The only thing we want to check there is that the registration doesn't take place in the debugger thread. Disallowing registrations from anywhere but the main GUI thread creates unnecessary problems with threaded QML profiling and debugging. Change-Id: Ic72d19237e2ddba02cc88f7f5a0743f6640fed4d Reviewed-by: Simon Hausmann <simon.hausmann@digia.com>
Diffstat (limited to 'src/qml/debugger')
-rw-r--r--src/qml/debugger/qqmldebugserver.cpp8
1 files changed, 4 insertions, 4 deletions
diff --git a/src/qml/debugger/qqmldebugserver.cpp b/src/qml/debugger/qqmldebugserver.cpp
index 0523762971..c21911a43f 100644
--- a/src/qml/debugger/qqmldebugserver.cpp
+++ b/src/qml/debugger/qqmldebugserver.cpp
@@ -547,8 +547,8 @@ bool QQmlDebugServer::addService(QQmlDebugService *service)
{
Q_D(QQmlDebugServer);
- // to be executed in GUI thread
- Q_ASSERT(QThread::currentThread() == QCoreApplication::instance()->thread());
+ // to be executed outside of debugger thread
+ Q_ASSERT(QThread::currentThread() != thread());
{
QWriteLocker lock(&d->pluginsLock);
@@ -571,8 +571,8 @@ bool QQmlDebugServer::removeService(QQmlDebugService *service)
{
Q_D(QQmlDebugServer);
- // to be executed in GUI thread
- Q_ASSERT(QThread::currentThread() == QCoreApplication::instance()->thread());
+ // to be executed outside of debugger thread
+ Q_ASSERT(QThread::currentThread() != thread());
{
QWriteLocker lock(&d->pluginsLock);