orion_old/libc/stdlib/abort.c

14 lines
266 B
C
Raw Normal View History

2021-08-04 15:14:22 +00:00
#include <stdio.h>
#include <stdlib.h>
__attribute__((__noreturn__))
void abort(void) {
#if defined(__is_libk)
// TODO: Add proper kernel panic.
panic("abort()\n");
2021-08-04 15:14:22 +00:00
#else
// TODO: Abnormally terminate the process as if by SIGABRT.
printf("abort()\n");
#endif
}