Skip to content

Commit

Permalink
Increase debug verbosity
Browse files Browse the repository at this point in the history
  • Loading branch information
rvaiya committed Jul 20, 2022
1 parent a26ea19 commit 99a7869
Showing 1 changed file with 7 additions and 5 deletions.
12 changes: 7 additions & 5 deletions src/device.c
Original file line number Diff line number Diff line change
Expand Up @@ -83,14 +83,16 @@ static int device_init(const char *path, struct device *dev)

type = resolve_device_type(fd);

if (ioctl(fd, EVIOCGNAME(sizeof(dev->name)), dev->name) == -1) {
perror("ioctl EVIOCGNAME");
return -1;
}

dbg2("device type of %s (%s): %x", path, dev->name, type);

if (type) {
struct input_id info;

if (ioctl(fd, EVIOCGNAME(sizeof(dev->name)), dev->name) == -1) {
perror("ioctl EVIOCGNAME");
return -1;
}

if (ioctl(fd, EVIOCGID, &info) == -1) {
perror("ioctl EVIOCGID");
return -1;
Expand Down

0 comments on commit 99a7869

Please sign in to comment.