mirror of
https://gitlab.freedesktop.org/libevdev/libevdev.git
synced 2025-12-25 03:30:06 +01:00
tools: pass -rc to strerror, not rc
rc is a negative errno Found by Coverity. Signed-off-by: Peter Hutterer <peter.hutterer@who-t.net>
This commit is contained in:
parent
53958c56cd
commit
400e52c6a2
1 changed files with 1 additions and 1 deletions
|
|
@ -185,7 +185,7 @@ main(int argc, char **argv)
|
|||
} while (rc == LIBEVDEV_READ_STATUS_SYNC || rc == LIBEVDEV_READ_STATUS_SUCCESS || rc == -EAGAIN);
|
||||
|
||||
if (rc != LIBEVDEV_READ_STATUS_SUCCESS && rc != -EAGAIN)
|
||||
fprintf(stderr, "Failed to handle events: %s\n", strerror(rc));
|
||||
fprintf(stderr, "Failed to handle events: %s\n", strerror(-rc));
|
||||
|
||||
rc = 0;
|
||||
out:
|
||||
|
|
|
|||
Loading…
Add table
Reference in a new issue