[server] Properly handle the situation when the DataSource for a drag gets destroyed
ClosedPublic

Authored by graesslin on Jan 27 2018, 1:16 PM.

Details

Summary

This addresses the following situation:

  1. Start drag on a QtWayland based window
  2. Press escape
  3. Release mouse

-> this results in a crash. The main reason for this is that QtWayland
destroys the DataSource in step 2 and KWayland did not expect this at
all. The drag and drop operation continued and results in step 3 in the
drag target to request data from the no longer existing DataSource.

This change addresses the root of the problem by cancelling the drag
operation when the DataSource gets destroyed.

BUG: 389221
FIXED-IN: 5.43

Test Plan

New test case exposing the problem and manual testing with
kwin_wayland and dolphin (based on bug report)

Diff Detail

Repository
R127 KWayland
Branch
cancel-drag-on-datasource-destroy
Lint
No Linters Available
Unit
No Unit Test Coverage
graesslin created this revision.Jan 27 2018, 1:16 PM
Restricted Application added projects: Plasma on Wayland, Frameworks. · View Herald TranscriptJan 27 2018, 1:16 PM
Restricted Application added a subscriber: plasma-devel. · View Herald Transcript
graesslin requested review of this revision.Jan 27 2018, 1:16 PM
Restricted Application edited projects, added Plasma; removed Plasma on Wayland. · View Herald TranscriptJan 27 2018, 1:16 PM
Restricted Application edited projects, added Plasma on Wayland; removed Plasma. · View Herald TranscriptFeb 7 2018, 6:43 PM
Restricted Application edited projects, added Plasma; removed Plasma on Wayland. · View Herald TranscriptFeb 21 2018, 5:11 PM
romangg accepted this revision.Feb 24 2018, 8:34 PM
This revision is now accepted and ready to land.Feb 24 2018, 8:34 PM
Restricted Application edited projects, added Plasma on Wayland; removed Plasma. · View Herald TranscriptFeb 24 2018, 8:34 PM
This revision was automatically updated to reflect the committed changes.
Restricted Application edited projects, added Plasma; removed Plasma on Wayland. · View Herald TranscriptFeb 25 2018, 1:15 PM