summaryrefslogtreecommitdiffstats
path: root/src/corelib/json/qjsonparser.cpp
diff options
context:
space:
mode:
authorMarc Mutz <marc.mutz@kdab.com>2013-09-20 02:38:22 +0200
committerMarc Mutz <marc.mutz@kdab.com>2016-11-20 15:48:05 +0000
commit3691f7ca0c7117f18ea38ca3950ee9a8a91a53c8 (patch)
treec17a602be94f46bf51a51726bf0472aa51c1ecba /src/corelib/json/qjsonparser.cpp
parentf1b4bd4790860e1ff5afcec111a359bc3a91cfda (diff)
QFutureInterface: make accesses to 'state' thread-safe
Introduce helper functions switch_{on,off,from_to} to make the code more readable, and prepare everything for later optimizations reducing the sizes of critical sections (by locking the mutex later, or even never). This commit, however, is only concerned with shutting up tsan. In waitForResult(), simplified the code by removing an unneeded if guard: the condition is checked in the while loop immediately following in the then-block, and the local variable declaration that precedes the loop is not worth guarding. Change-Id: I24bfd864ca96f862302536ad8662065e6f366fa8 Reviewed-by: David Faure <david.faure@kdab.com>
Diffstat (limited to 'src/corelib/json/qjsonparser.cpp')
0 files changed, 0 insertions, 0 deletions