Engine/lib/sdl/src/core/linux/SDL_evdev.c
/* Prevent keystrokes from reaching the tty */
Prevent keystrokes from reaching the tty
Prevent keystrokes from reaching the tty
static int SDL_EVDEV_mute_keyboard(int tty, int *kb_mode)
{
    char arg;
    *kb_mode = 0; 
    if (!IS_CONSOLE(tty)) {
        return SDL_SetError("Tried to mute an invalid tty");
    }
    ioctl(tty, KDGKBMODE, kb_mode); 
    if (ioctl(tty, KDSKBMUTE, 1) && ioctl(tty, KDSKBMODE, K_OFF)) {
        return SDL_SetError("EVDEV: Failed muting keyboard");
    }
    return 0;  
}
static int SDL_EVDEV_mute_keyboard ( int tty , int * kb_mode ) { char arg ; * kb_mode = 0 ; if ( ! IS_CONSOLE ( tty ) ) { return SDL_SetError ( " " ) ; } ioctl ( tty , KDGKBMODE , kb_mode ) ; if ( ioctl ( tty , KDSKBMUTE , 1 ) && ioctl ( tty , KDSKBMODE , K_OFF ) ) { return SDL_SetError ( " " ) ; } return 0 ; }
Prevent keystrokes from reaching the tty
Prevent keystrokes from reaching the tty
/* FIXME: Is this a sane default in case KDGKBMODE fails? */ /* It's not fatal if this fails */