GNOME Bugzilla – Bug 787649
Mutter may segfault if a tablet is quickly connected and disconnected
Last modified: 2017-09-28 13:58:49 UTC
If a Wacom tablet is connected and quickly disconnected, an Xorg mutter may crash with a segfault with the following backtrace. It appears that this is caused by `XIQueryDevice` returning a NULL `info` pointer and a negative value for `n_devices`. The check within `device_query_area` only checks for `n_devices == 0`, allowing the NULL pointer to be dereferenced later on. Reproducing this issue is more easily done by repeatedly loading and unloading the wacom kernel module, e.g. as done by https://gist.github.com/jigpu/126d22e5fbb977b83fbc16f82bcace0a Program terminated with signal SIGSEGV, Segmentation fault.
+ Trace 237958
Created attachment 359745 [details] [review] backends/x11: Prevent segfault when querying list of devices Patch which fixes the segfault
Review of attachment 359745 [details] [review]: lgtm
Does someone need to be CCd to commit this patch?
Attachment 359745 [details] pushed as 8493777 - backends/x11: Prevent segfault when querying list of devices