summaryrefslogtreecommitdiffstats
path: root/src/corelib/io/qprocess_win.cpp
diff options
context:
space:
mode:
authorDavid Faure <david.faure@kdab.com>2013-03-18 15:19:44 +0100
committerThe Qt Project <gerrit-noreply@qt-project.org>2013-03-22 16:44:51 +0100
commitf4609b202208fe592d24c7ae3b4a48ee83045497 (patch)
treec9827efe74688595664c379085ba2a6267e49c13 /src/corelib/io/qprocess_win.cpp
parent85b25fc22176b574865813fa53f7eb2fcbdc89bf (diff)
QThread: fix race when setting the eventDispatcher
Use QAtomicPointer to make this thread-safe. Change-Id: If71f204699fcefabdb59bd26342d777d1cc9e2a7 Reviewed-by: Olivier Goffart <ogoffart@woboq.com>
Diffstat (limited to 'src/corelib/io/qprocess_win.cpp')
-rw-r--r--src/corelib/io/qprocess_win.cpp2
1 files changed, 1 insertions, 1 deletions
diff --git a/src/corelib/io/qprocess_win.cpp b/src/corelib/io/qprocess_win.cpp
index ab1f05777a..0f36c3adbf 100644
--- a/src/corelib/io/qprocess_win.cpp
+++ b/src/corelib/io/qprocess_win.cpp
@@ -528,7 +528,7 @@ void QProcessPrivate::startProcess()
if (!pid)
return;
- if (threadData->eventDispatcher) {
+ if (threadData->hasEventDispatcher()) {
processFinishedNotifier = new QWinEventNotifier(pid->hProcess, q);
QObject::connect(processFinishedNotifier, SIGNAL(activated(HANDLE)), q, SLOT(_q_processDied()));
processFinishedNotifier->setEnabled(true);