summaryrefslogtreecommitdiff
path: root/doc/src/snippets/code/src_sql_kernel_qsqldatabase.cpp
diff options
context:
space:
mode:
authorThiago Macieira <thiago.macieira@nokia.com>2010-05-18 15:58:24 +0200
committerThiago Macieira <thiago.macieira@nokia.com>2010-05-24 21:09:31 +0200
commitfd256203708e79d64bad856e39bb5a43357bfd06 (patch)
tree7ec4edc7310b4a0724c3d6ffd3fce8a234f7c0c2 /doc/src/snippets/code/src_sql_kernel_qsqldatabase.cpp
parent314a36895e1a31dd2b62de265d9160238d96e512 (diff)
downloadqt4-tools-fd256203708e79d64bad856e39bb5a43357bfd06.tar.gz
Fix a race condition with QtDBus blocking for replies.
If an auxiliary thread tried to block on waiting for a reply, and at the same time the main thread handled the reply, there's room for a race condition. So ensure only one thread is stopped at dbus_pending_call_block(). The other thread(s) will be waiting on the QWaitCondition. It's not a race condition for the main thread to process (and finish processing) the reply while the auxiliary thread hasn't even started to wait. The code will ensure that the reply is properly seen. Task-Id: https://projects.maemo.org/bugzilla/show_bug.cgi?id=155306 Reviewed-By: Trust Me
Diffstat (limited to 'doc/src/snippets/code/src_sql_kernel_qsqldatabase.cpp')
0 files changed, 0 insertions, 0 deletions