From: John Hodge (sonata) Date: Sun, 11 Aug 2013 14:51:42 +0000 (+0800) Subject: Modules/Keyboard - Hacked-up Ctrl-Alt-Del triple fault X-Git-Tag: rel0.15~270 X-Git-Url: https://git.ucc.asn.au/?a=commitdiff_plain;ds=sidebyside;h=c002deb480339b26cd38c3c149d59a179735860e;p=tpg%2Facess2.git Modules/Keyboard - Hacked-up Ctrl-Alt-Del triple fault --- diff --git a/KernelLand/Modules/Input/Keyboard/main.c b/KernelLand/Modules/Input/Keyboard/main.c index 9c2e20e6..16602be8 100644 --- a/KernelLand/Modules/Input/Keyboard/main.c +++ b/KernelLand/Modules/Input/Keyboard/main.c @@ -298,5 +298,19 @@ void Keyboard_HandleKey(tKeyboard *Source, Uint32 HIDKeySym) } #endif + #if defined(ARCHDIR_is_x86) || defined(ARCHDIR_is_x86_64) + if(bPressed + && Source->KeyStates[KEYSYM_LEFTCTRL/8] & (1 << (KEYSYM_LEFTCTRL&7)) + && Source->KeyStates[KEYSYM_LEFTALT/8] & (1 << (KEYSYM_LEFTALT &7)) ) + { + if( HIDKeySym == KEYSYM_DELETE ) + { + // Trigger triple fault + __asm__ __volatile__ ("lgdt (%esp) ; int $0x0"); + for(;;); + } + } + #endif + }