← Commit list

651d49a2c

Denis Vlasenko
Denis Vlasenko
2008-09-28
FAILED Duration: 29s

Subject

showkey: suppress gcc warning

Binary

No binary (build failed)

Architecture & Compiler Flags

Architecture: x86_64-linux-gnu Compiler: gcc (Ubuntu 11.4.0-1ubuntu1~22.04.3) 11.4.0

—

Build Log

(log yok)

Commit Diff GitHub →

console-tools/showkey.c+2 -2
@@ -50,7 +50,7 @@ static void signal_handler(int signo)
{
// restore keyboard and console settings
xset1(STDIN_FILENO, &tio0, "stdin");
- xioctl(STDIN_FILENO, KDSKBMODE, (void *)kbmode);
+ xioctl(STDIN_FILENO, KDSKBMODE, (void *)(ptrdiff_t)kbmode);
// alarmed? -> exit 0
exit(SIGALRM == signo);
}
@@ -95,7 +95,7 @@ int showkey_main(int argc UNUSED_PARAM, char **argv)
// we should exit on any signal
bb_signals(BB_FATAL_SIGS, signal_handler);
// set raw keyboard mode
- xioctl(STDIN_FILENO, KDSKBMODE, (void *)((option_mask32 & OPT_k) ? K_MEDIUMRAW : K_RAW));
+ xioctl(STDIN_FILENO, KDSKBMODE, (void *)(ptrdiff_t)((option_mask32 & OPT_k) ? K_MEDIUMRAW : K_RAW));
// read and show scancodes
while (1) {