Handle errors with drmModeSetCursor instead of silently failing
ClosedPublic

Authored by garg on Apr 22 2018, 1:20 PM.

Details

Summary

Make sure we switch to a software cursor when drmModeSetCursor
fails.

Diff Detail

Repository
R108 KWin
Lint
Automatic diff as part of commit; lint not applicable.
Unit
Automatic diff as part of commit; unit tests not applicable.
garg created this revision.Apr 22 2018, 1:20 PM
Restricted Application added a project: KWin. · View Herald TranscriptApr 22 2018, 1:20 PM
Restricted Application added a subscriber: kwin. · View Herald Transcript
garg requested review of this revision.Apr 22 2018, 1:20 PM
garg updated this revision to Diff 32806.Apr 22 2018, 2:28 PM

Make sure we return the right value

graesslin added inline comments.Apr 22 2018, 3:21 PM
plugins/platforms/drm/drm_backend.cpp
658–660

nitpick coding style: whitespace between if and (

plugins/platforms/drm/drm_output.cpp
112–116

const int or rather bool ;-)

plugins/platforms/drm/drm_output.h
69–72

as we don't use the return value, I suggest to turn it into bool

garg updated this revision to Diff 32825.Apr 22 2018, 4:12 PM

Update as per comments

graesslin added inline comments.Apr 22 2018, 7:09 PM
plugins/platforms/drm/drm_backend.cpp
658–660

here you had the same coding style error :-)

plugins/platforms/drm/drm_output.cpp
99

the const here doesn't make sense

garg updated this revision to Diff 32840.Apr 22 2018, 7:46 PM

Update return types

graesslin accepted this revision.Apr 23 2018, 4:26 AM
This revision is now accepted and ready to land.Apr 23 2018, 4:26 AM
This revision was automatically updated to reflect the committed changes.