Tell the user via BOARD if load_libc() failed

git-svn-id: svn://kolibrios.org@6902 a494cfbc-eb01-0410-851d-a64ba20cac60
This commit is contained in:
ashmew2 2017-05-21 10:01:10 +00:00
parent f4669d53a9
commit 08d66341b6
1 changed files with 8 additions and 0 deletions

View File

@ -21,6 +21,14 @@ __crt_startup (void)
if(!img)
{
// Inform the user via BOARD that libc could not be loaded.
char *errormsg = "[ERROR] libc.dll failed to load. is /kolibrios folder configured?\n";
while (*errormsg) {
__asm__ __volatile__("int $0x40"::"a"(63), "b"(1), "c"(*errormsg));
++errormsg;
}
// Exit
asm ("int $0x40" ::"a"(-1));
};