summaryrefslogtreecommitdiffstats
path: root/src/kernel/qeventloop_unix.cpp
diff options
context:
space:
mode:
authorTimothy Pearson <kb9vqf@pearsoncomputing.net>2012-12-06 18:29:37 -0600
committerTimothy Pearson <kb9vqf@pearsoncomputing.net>2012-12-06 18:29:37 -0600
commitcaf80d88243aaa00e8f1baeaa6b7e4c3aca75f63 (patch)
tree860926c1e01068a8d3b8ea120630a48cf537424b /src/kernel/qeventloop_unix.cpp
parent78125ea2f051107b84fdc0354acdedb7885308ee (diff)
downloadqt3-caf80d88243aaa00e8f1baeaa6b7e4c3aca75f63.tar.gz
qt3-caf80d88243aaa00e8f1baeaa6b7e4c3aca75f63.zip
Add threading tutorial and fix a couple rare crashes
Diffstat (limited to 'src/kernel/qeventloop_unix.cpp')
-rw-r--r--src/kernel/qeventloop_unix.cpp2
1 files changed, 2 insertions, 0 deletions
diff --git a/src/kernel/qeventloop_unix.cpp b/src/kernel/qeventloop_unix.cpp
index 202ef12..80c8f29 100644
--- a/src/kernel/qeventloop_unix.cpp
+++ b/src/kernel/qeventloop_unix.cpp
@@ -562,6 +562,8 @@ int QEventLoop::activateTimers()
n_act++;
QTimerEvent e( t->id );
QApplication::sendEvent( t->obj, &e ); // send event
+ if ( !timerList ) // sendEvent allows other threads to execute, therefore we must check for list existence when it returns!
+ return 0;
if ( timerList->findRef( begin ) == -1 )
begin = 0;
}