Luna/libs/libc/src/luna.cpp

25 lines
451 B
C++
Raw Normal View History

#include <luna.h>
#include <stdio.h>
#include <stdlib.h>
#include <string.h>
#include <sys/syscall.h>
#include <unistd.h>
extern "C"
{
long getprocid(int field)
{
return syscall(SYS_getprocid, field);
}
unsigned int msleep(unsigned int ms)
{
2022-10-07 16:19:06 +00:00
return (unsigned int)syscall(SYS_sleep, ms);
}
__lc_noreturn void __luna_abort(const char* message)
{
2022-10-12 09:54:29 +00:00
fputs(message, stderr);
abort();
}
}