summaryrefslogtreecommitdiff
path: root/console-tools/setkeycodes.c
diff options
context:
space:
mode:
Diffstat (limited to 'console-tools/setkeycodes.c')
-rw-r--r--console-tools/setkeycodes.c6
1 files changed, 3 insertions, 3 deletions
diff --git a/console-tools/setkeycodes.c b/console-tools/setkeycodes.c
index 0911ede..3de5f98 100644
--- a/console-tools/setkeycodes.c
+++ b/console-tools/setkeycodes.c
@@ -39,9 +39,9 @@ int setkeycodes_main(int argc, char** argv)
a.scancode -= 0xe000;
a.scancode += 128;
}
- if (ioctl(fd, KDSETKEYCODE, &a)) {
- bb_perror_msg_and_die("failed to set SCANCODE %x to KEYCODE %d", sc, a.keycode);
- }
+ ioctl_or_perror_and_die(fd, KDSETKEYCODE, &a,
+ "failed to set SCANCODE %x to KEYCODE %d",
+ sc, a.keycode);
argc -= 2;
argv += 2;
}