xserver-multidpi/hw
Olivier Fourdan 18fcb66688 xwayland: Monitor client states to destroy callbacks
In XWayland, dri3_send_open_reply() is called from a sync callback, so
there is a possibility that the client might be gone when we get to the
callback eventually, which leads to a crash in _XSERVTransSendFd() from
WriteFdToClient() .

Client resources can survive the client itself, in which case we
may end up in our sync callback trying to access client's data after
it's been freed/reclaimed.

Add a ClientStateCallback handler to monitor the client state changes
and clear the sync callback set up by the glamor drm code if any.

Fixes: https://bugzilla.redhat.com/show_bug.cgi?id=1416553
Fixes: https://bugs.freedesktop.org/show_bug.cgi?id=100040
Tested-by: Mark B <mark.blakeney@bullet-systems.net>
Signed-off-by: Olivier Fourdan <ofourdan@redhat.com>
Reviewed-by: Michel Dänzer <michel.daenzer@amd.com>
(cherry picked from commit 937527f979)
2017-03-13 09:56:24 +01:00
..
dmx ddx: add new call to purge input devices that weren't added 2016-10-26 15:35:07 +10:00
kdrive ephyr: Leave window unmapped for -glamor-skip-present [v2] 2016-10-28 08:41:28 -07:00
vfb Remove fd_set from Block/Wakeup handler API 2016-07-18 15:27:51 -04:00
xfree86 xfree86: Take input_lock() for xf86ScreenCheckHWCursor 2017-02-17 10:14:03 +10:00
xnest Remove fd_set from Block/Wakeup handler API 2016-07-18 15:27:51 -04:00
xquartz ddx: add new call to purge input devices that weren't added 2016-10-26 15:35:07 +10:00
xwayland xwayland: Monitor client states to destroy callbacks 2017-03-13 09:56:24 +01:00
xwin hw/xwin: Add 'dri' to DIST_SUBDIRS 2016-09-16 10:57:23 -07:00
Makefile.am Xwayland DDX 2014-04-03 15:19:22 -07:00