Print error on Setsu open failure

This commit is contained in:
Florian Märkl 2021-01-06 11:35:56 +01:00
commit 20c54b05ad
No known key found for this signature in database
GPG key ID: 125BC8A5A6A1E857

View file

@ -309,7 +309,11 @@ SetsuDevice *setsu_connect(Setsu *setsu, const char *path, SetsuDeviceType type)
dev->fd = open(dev->path, O_RDONLY | O_NONBLOCK);
if(dev->fd == -1)
{
SETSU_LOG("Failed to open %s\n", dev->path);
perror("setsu_connect");
goto error;
}
if(libevdev_new_from_fd(dev->fd, &dev->evdev) < 0)
{