diff options
| author | Volker Hilsheimer <volker.hilsheimer@qt.io> | 2019-10-08 10:56:44 +0200 |
|---|---|---|
| committer | Shawn Rutledge <shawn.rutledge@qt.io> | 2019-10-10 11:02:34 +0000 |
| commit | 3dbc7596a3b7aca37e80f76288d3ab761ddd247a (patch) | |
| tree | ef4edb907a016d7197dc538164dcc94a340b2aa7 /src/testlib/doc/snippets/code | |
| parent | 9845c06d1f8c3b30697cdf96b569849ee2372f47 (diff) | |
Drag'n'Drop: fix crash when widgets are destroyed during event handling
Widgets might be destroyed when handling a dragMoveEvent, in which case
the following code will operate on dangling pointers or null pointers.
Use a QPointer to watch for the original event receiver to disappear,
and add the necessary checks for the objects we deliver events to being
null.
Change-Id: I4ca2f182540ae21113f4bea4e5c569e983cc58bf
Fixes: QTBUG-78907
Reviewed-by: Gatis Paeglis <gatis.paeglis@qt.io>
Diffstat (limited to 'src/testlib/doc/snippets/code')
0 files changed, 0 insertions, 0 deletions
