- Set up the real-mode IDT.
[AROS.git] / arch / all-unix / kernel / maygetchar.c
blobf787ccb6c74bd310c32c2f2e3e5defb451f892ad
1 #include <aros/libcall.h>
3 #include <unistd.h>
5 #include "kernel_base.h"
6 #include "kernel_intern.h"
8 AROS_LH0(int, KrnMayGetChar,
9 struct KernelBase *, KernelBase, 26, Kernel)
11 AROS_LIBFUNC_INIT
13 char c;
14 int ret;
16 ret = KernelBase->kb_PlatformData->iface->read (STDERR_FILENO, &c, 1);
17 AROS_HOST_BARRIER
19 return (ret == 1) ? c : -1;
21 AROS_LIBFUNC_EXIT