mirror of
https://github.com/brl/mutter.git
synced 2024-12-23 11:32:04 +00:00
native: Actually close input device fds
Don't only release it, also close the fd so that we don't leak it. https://bugzilla.gnome.org/show_bug.cgi?id=752753
This commit is contained in:
parent
ac79988939
commit
7ce06928e2
@ -223,7 +223,7 @@ on_evdev_device_close (int fd,
|
|||||||
if (!get_device_info_from_fd (fd, &major, &minor))
|
if (!get_device_info_from_fd (fd, &major, &minor))
|
||||||
{
|
{
|
||||||
g_warning ("Could not get device info for fd %d: %m", fd);
|
g_warning ("Could not get device info for fd %d: %m", fd);
|
||||||
return;
|
goto out;
|
||||||
}
|
}
|
||||||
|
|
||||||
if (!login1_session_call_release_device_sync (self->session_proxy,
|
if (!login1_session_call_release_device_sync (self->session_proxy,
|
||||||
@ -232,6 +232,9 @@ on_evdev_device_close (int fd,
|
|||||||
{
|
{
|
||||||
g_warning ("Could not release device %d,%d: %s", major, minor, error->message);
|
g_warning ("Could not release device %d,%d: %s", major, minor, error->message);
|
||||||
}
|
}
|
||||||
|
|
||||||
|
out:
|
||||||
|
close (fd);
|
||||||
}
|
}
|
||||||
|
|
||||||
static void
|
static void
|
||||||
|
Loading…
Reference in New Issue
Block a user