18 lines
280 B
C
18 lines
280 B
C
|
|
#include <stdint.h>
|
||
|
|
#include <efi.h>
|
||
|
|
#include <efilib.h>
|
||
|
|
|
||
|
|
#define STACK_CHK_GUARD 0x595e9fbd94fda766
|
||
|
|
|
||
|
|
uintptr_t __stack_chk_guard = STACK_CHK_GUARD;
|
||
|
|
|
||
|
|
_Noreturn void
|
||
|
|
__stack_chk_fail(void)
|
||
|
|
{
|
||
|
|
Print(L"stack smashing detected");
|
||
|
|
for (;;) {
|
||
|
|
__asm__ ("cli\n\thlt\n\t" ::);
|
||
|
|
}
|
||
|
|
}
|
||
|
|
|