factor/vm/os-windows-ce.c

44 lines
745 B
C
Raw Normal View History

2007-09-20 18:09:08 -04:00
#include "master.h"
s64 current_millis(void)
{
SYSTEMTIME st;
FILETIME ft;
GetSystemTime(&st);
SystemTimeToFileTime(&st, &ft);
return (((s64)ft.dwLowDateTime
| (s64)ft.dwHighDateTime<<32) - EPOCH_OFFSET) / 10000;
}
DEFINE_PRIMITIVE(cwd)
{
not_implemented_error();
}
DEFINE_PRIMITIVE(cd)
{
not_implemented_error();
}
char *strerror(int err)
{
/* strerror() is not defined on WinCE */
2007-10-13 00:57:24 -04:00
return "strerror() is not defined on WinCE. Use native I/O.";
2007-09-20 18:09:08 -04:00
}
2007-10-13 00:57:24 -04:00
void flush_icache(CELL start, CELL end)
2007-09-20 18:09:08 -04:00
{
FlushInstructionCache(GetCurrentProcess(), 0, 0);
}
char *getenv(char *name)
{
not_implemented_error();
return 0; /* unreachable */
}
long exception_handler(PEXCEPTION_RECORD rec, void *frame, void *ctx, void *dispatch)
{
2007-10-13 00:57:24 -04:00
return 0;
}