evdev: fix a warning. fd should have initialized value.
authorGwanglim Lee <gl77.lee@samsung.com>
Tue, 23 Aug 2016 02:16:18 +0000 (11:16 +0900)
committerJengHyun Kang <jhyuni.kang@samsung.com>
Tue, 24 Oct 2017 07:04:33 +0000 (16:04 +0900)
Change-Id: I699f8c714210d59aef57bf715ded91739bf1342a

src/evdev.c

index c4da1db2798c411356168e893f3c4cb345272ec1..c142dc5dc38f8a517caebac509d1eb9bb1feeaff 100644 (file)
@@ -3058,7 +3058,7 @@ evdev_device_create(struct libinput_seat *seat,
        struct libinput *libinput = seat->libinput;
        struct evdev_device *device = NULL;
        int rc;
-       int fd;
+       int fd = -1;
        int unhandled_device = 0;
        const char *devnode = udev_device_get_devnode(udev_device);
        const char *sysname = udev_device_get_sysname(udev_device);