From 91e7855bd64c22416f1dbe0865818fb88363d289 Mon Sep 17 00:00:00 2001 From: Toad King Date: Tue, 19 Jun 2012 15:26:09 -0400 Subject: [PATCH] only detect CTRL+C for SIGINT, not C+CTRL --- input/linuxraw_input.c | 6 +++--- 1 file changed, 3 insertions(+), 3 deletions(-) diff --git a/input/linuxraw_input.c b/input/linuxraw_input.c index a0069c3eba..451a76a1e3 100644 --- a/input/linuxraw_input.c +++ b/input/linuxraw_input.c @@ -280,6 +280,9 @@ static void linuxraw_input_poll(void *data) while (read(0, &c, 1) > 0) { + if (c == KEY_C && (linuxraw->state[KEY_LEFTCTRL] || linuxraw->state[KEY_RIGHTCTRL])) + kill(getpid(), SIGINT); + bool pressed = !(c & 0x80); c &= ~0x80; @@ -290,9 +293,6 @@ static void linuxraw_input_poll(void *data) linuxraw->state[c] = pressed; } - if (linuxraw->state[KEY_C] && (linuxraw->state[KEY_LEFTCTRL] || linuxraw->state[KEY_RIGHTCTRL])) - kill(getpid(), SIGINT); - input_sdl.poll(linuxraw->sdl); }