D7078: [server] Fix crash when sending selection to a DDI without a DataSource

David Edmundson noreply at phabricator.kde.org
Wed Aug 9 16:55:15 UTC 2017


davidedmundson added a comment.


  I don't think we did go in there because we have a selection, otherwise other->selection() wouldn't be null.
  
  If we want DDI::sendSelection(DDI *other) to always keep the client in sync we should do:
  
    auto selection = other->selection();
    if (!selection) {
        sendClearSelection();
        return;
    }
  
  the send_selection spec says we should be passing a null resource if we have no selection, whereas this version creates a data offer with nothing in it.

REPOSITORY
  R127 KWayland

REVISION DETAIL
  https://phabricator.kde.org/D7078

To: graesslin, #kwin, #plasma, #frameworks
Cc: davidedmundson, plasma-devel, leezu, ZrenBot, progwolff, lesliezhai, ali-mohamed, jensreuterberg, abetts, eliasp, sebas, apol, mart, hein, lukas
-------------- next part --------------
An HTML attachment was scrubbed...
URL: <http://mail.kde.org/pipermail/plasma-devel/attachments/20170809/d6f63310/attachment-0001.html>


More information about the Plasma-devel mailing list