banan-os/libc/stdio/putchar.cpp

17 lines
240 B
C++
Raw Normal View History

#include <stdio.h>
#if defined(__is_libk)
#include <kernel/panic.h>
2022-11-14 00:27:11 +02:00
#else
#include <stdlib.h>
#endif
int putchar(int c)
{
#if defined(__is_libk)
2022-11-15 21:42:14 +02:00
Kernel::panic("Please use kprint() instead of stdio");
#else
2022-11-14 00:27:11 +02:00
abort();
#endif
return c;
}