forked from enlightenment/efl
ecore-drm: Free devices before we release the libinput reference
Summary: When destroying evdev devices, we make calls to libinput_device_unref ... but we cannot Make that call if the libinput context has been destroyed already (as happens when we free input). So to fix, don't release the libinput context until all devices have been released. @fix Signed-off-by: Chris Michael <cp.michael@samsung.com>
This commit is contained in:
parent
251c300b8f
commit
0b77b7f59f
|
@ -295,13 +295,6 @@ ecore_drm_inputs_destroy(Ecore_Drm_Device *dev)
|
|||
Ecore_Drm_Seat *seat;
|
||||
Ecore_Drm_Evdev *edev;
|
||||
|
||||
EINA_LIST_FREE(dev->inputs, input)
|
||||
{
|
||||
if (input->hdlr) ecore_main_fd_handler_del(input->hdlr);
|
||||
if (input->libinput) libinput_unref(input->libinput);
|
||||
free(input);
|
||||
}
|
||||
|
||||
EINA_LIST_FREE(dev->seats, seat)
|
||||
{
|
||||
EINA_LIST_FREE(seat->devices, edev)
|
||||
|
@ -310,6 +303,13 @@ ecore_drm_inputs_destroy(Ecore_Drm_Device *dev)
|
|||
if (seat->name) eina_stringshare_del(seat->name);
|
||||
free(seat);
|
||||
}
|
||||
|
||||
EINA_LIST_FREE(dev->inputs, input)
|
||||
{
|
||||
if (input->hdlr) ecore_main_fd_handler_del(input->hdlr);
|
||||
if (input->libinput) libinput_unref(input->libinput);
|
||||
free(input);
|
||||
}
|
||||
}
|
||||
|
||||
EAPI Eina_Bool
|
||||
|
|
Loading…
Reference in New Issue