diff options
author | Alex Trotsenko <alex1973tr@gmail.com> | 2017-08-17 09:16:16 +0300 |
---|---|---|
committer | Edward Welbourne <edward.welbourne@qt.io> | 2017-08-18 07:25:52 +0000 |
commit | 362466c7d2e12c4587d5de1eb51cd537be9f7e2b (patch) | |
tree | 28a1cf1e209d32e6d69030a05a1069d59e26c449 /tests/manual/qtabbar/tabbarform.ui | |
parent | 1cd91a0ee58a653e7543dc01988d92adc89d3116 (diff) |
QProcess/Unix: fix possible race condition inside waitForXXX() loops
Calling QCoreApplication::processEvents() from a slot connected to the
readyRead() signal might cause desynchronization in the waitForXXX()
loop, if the process has been finished during the event processing.
This results in unnecessary timeouts and causes waitForFinished() to
fail unexpectedly.
So, a proposed solution is to check the state on each iteration of the
loop, as Windows implementation does.
Given issue is tested by tst_QProcess::processEventsInAReadyReadSlot()
which was unstable in CI.
Task-number: QTBUG-62584
Change-Id: I7438cf67b0163bbf49314008a9dc660c0977fb7b
Reviewed-by: Thiago Macieira <thiago.macieira@intel.com>
Diffstat (limited to 'tests/manual/qtabbar/tabbarform.ui')
0 files changed, 0 insertions, 0 deletions