Syncboot/libc/stdlib/abort.c
2019-04-01 02:18:48 +01:00

15 lines
282 B
C
Executable File

#include <stdio.h>
#include <stdlib.h>
__attribute__((__noreturn__))
void abort(void) {
#if defined(__is_libk)
//TODO: Kernel panic.
printf(">>PANIC<<<\n abort() panicked!\n");
#else
printf("abort() called\n");
#endif
while(1) {}
__builtin_unreachable();
}