backend-wayland: do not try to release uninitialized seat
Do not call weston_seat_release() if Weston aborts before weston_seat_init() could be called. This fixes a possible segfault due to uninitialized list traversal in the error path. Signed-off-by: Philipp Zabel <p.zabel@pengutronix.de>
This commit is contained in:
parent
fdaf4cf320
commit
c448819b37
@ -2430,7 +2430,8 @@ wayland_input_destroy(struct wayland_input *input)
|
||||
if (input->touch_device)
|
||||
weston_touch_device_destroy(input->touch_device);
|
||||
|
||||
weston_seat_release(&input->base);
|
||||
if (input->seat_initialized)
|
||||
weston_seat_release(&input->base);
|
||||
|
||||
if (input->parent.keyboard) {
|
||||
if (input->seat_version >= WL_KEYBOARD_RELEASE_SINCE_VERSION)
|
||||
|
Loading…
x
Reference in New Issue
Block a user