From ae875520d1f8ae8ebf7beb98e8fcfc88bcef8c5a Mon Sep 17 00:00:00 2001 From: Peter Hutterer Date: Tue, 15 Apr 2014 14:28:00 +0200 Subject: [PATCH] touchpad: reset the tap timer_fd to -1 on destroy MIME-Version: 1.0 Content-Type: text/plain; charset=utf8 Content-Transfer-Encoding: 8bit No real effect, just for safety Signed-off-by: Peter Hutterer Signed-off-by: Hans de Goede Reviewed-by: Jonas Ådahl Reviewed-by: Hans de Goede --- src/evdev-mt-touchpad-tap.c | 4 +++- 1 file changed, 3 insertions(+), 1 deletion(-) diff --git a/src/evdev-mt-touchpad-tap.c b/src/evdev-mt-touchpad-tap.c index 5fa712f..bcc5700 100644 --- a/src/evdev-mt-touchpad-tap.c +++ b/src/evdev-mt-touchpad-tap.c @@ -615,6 +615,8 @@ tp_destroy_tap(struct tp_dispatch *tp) libinput_remove_source(tp->device->base.seat->libinput, tp->tap.source); tp->tap.source = NULL; } - if (tp->tap.timer_fd > -1) + if (tp->tap.timer_fd > -1) { close(tp->tap.timer_fd); + tp->tap.timer_fd = -1; + } } -- 2.7.4