compositor-drm: Fix crash when setting up seat constrained by an output
authorAnder Conselvan de Oliveira <ander.conselvan.de.oliveira@intel.com>
Thu, 17 Apr 2014 10:08:45 +0000 (13:08 +0300)
committerKristian Høgsberg <krh@bitplanet.net>
Mon, 21 Apr 2014 21:34:06 +0000 (14:34 -0700)
commit4ade0e4a29f4d7313bcc24cacd34596c110f7ba2
tree3946deaf794195fee841d7fbe77e8129df94b9a5
parent301f06b8948edce83138193e57a7d54110b18c3f
compositor-drm: Fix crash when setting up seat constrained by an output

Commit 58e15865 changed the parameters for udev_get_seat_by_name() to
receive a struct udev_input. However, when this gets called from
create_output_from_connector() during initialization, the input struct
is not yet initialized, leading to a crash. Previously, that function
would take only a pointer to the compositor.

This patch fixes the crash by initializing input before creating any
outputs.

Fixes: https://bugs.freedesktop.org/show_bug.cgi?id=77503
src/compositor-drm.c