swc

Unnamed repository; edit this file 'description' to name the repository.
git clone git://git.nihaljere.xyz/swc
Log | Files | Refs | README | LICENSE

commit ab2d2dbed1f03a3838ce6964ff07c92bd1662cdc
parent c86e36a96ee524a9c1a9cbf0e3dc7ed7dbc3a173
Author: Michael Forney <mforney@mforney.org>
Date:   Wed, 22 Jan 2014 14:37:42 -0800

evdev_device: Check to make sure source still exists before removing

Diffstat:
Mlibswc/evdev_device.c | 5+++--
1 file changed, 3 insertions(+), 2 deletions(-)

diff --git a/libswc/evdev_device.c b/libswc/evdev_device.c @@ -268,9 +268,10 @@ struct swc_evdev_device * swc_evdev_device_new void swc_evdev_device_destroy(struct swc_evdev_device * device) { - wl_event_source_remove(device->source); + if (device->source) + close_device(device); + libevdev_free(device->dev); - close(device->fd); free(device->path); free(device); }