diff options
author | Shawn Rutledge <shawn.rutledge@qt.io> | 2021-02-25 11:08:45 +0100 |
---|---|---|
committer | Qt Cherry-pick Bot <cherrypick_bot@qt-project.org> | 2021-03-19 07:53:14 +0000 |
commit | 44ae6793c7c1e902215542289a01b6c6032516b9 (patch) | |
tree | 803feace695498e3a1b94c5d9e95dfb73a6e07aa /src/qml | |
parent | 9321077b9233907f091919704825a3b9492b52c4 (diff) |
Add assertions and checks on QQWinPriv::deliveryAgentPrivate()
The static analyzer found the case where it could actually be null
during delivery of a WindowDeactivate event. In other cases, we assert
rather than testing, until we know that it can actually be null. It
shouldn't often be null because it's created in QQuickWindowPrivate::init()
and destroyed in the destructor; however we've already seen races when
event delivery continues while the window is being destroyed. If more
such cases materialize, we can replace asserts with if()'s or check
the new inDestructor flag.
Fixes static analyzer warning 16738055c4c458145b59ad9b6bb643b5
Change-Id: I408e9a7d71a77fd29c2af91e59caf9ede6585af9
Reviewed-by: Volker Hilsheimer <volker.hilsheimer@qt.io>
Reviewed-by: Qt CI Bot <qt_ci_bot@qt-project.org>
(cherry picked from commit fb69e86bee67a228ca581a8bfe3384da14398f76)
Reviewed-by: Qt Cherry-pick Bot <cherrypick_bot@qt-project.org>
Diffstat (limited to 'src/qml')
0 files changed, 0 insertions, 0 deletions