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

Martin Flöser noreply at phabricator.kde.org
Sun Aug 13 08:10:07 UTC 2017


graesslin added a comment.


  In https://phabricator.kde.org/D7078#135036, @davidedmundson wrote:
  
  > > So from KWayland Server side we have a selection
  >
  > from KWayland server side we have a Seat:selection, we don't check if that has a DDI::selection
  >
  >  ----
  >
  > If a client had called wl_set_selection(dataDevice, nulltptr)  the server would still have a registered DDI.
  >
  > If the client has called clearSelection to us, I think we should be sending clearSelection to X.
  
  
  of course we do that :-)
  
  Anyway, I would like to move further with that. This is a nullptr access fix which makes sense IMHO. If you think that we should not even send out the DataOffer I think that's a separate thing, which could be done in addition. So my suggestion would be to merge in this crash fix and in addition do the change you suggest.
  
  Please note that I doubt that your suggestion would help against the crash I fixed here. It fixes the autotest, but the autotest does not 100 % match the crash case we had in KWin. In KWin the crash was caused by an application crashing. When creating the autotest I simplified it to the common pattern. If we go for your change only the test would have to be adjusted to properly cover the situation from KWin.

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/kde-frameworks-devel/attachments/20170813/24e7d533/attachment.html>


More information about the Kde-frameworks-devel mailing list