source: trunk/libs/newlib/src/libgloss/libnosys/_exit.c @ 444

Last change on this file since 444 was 444, checked in by satin@…, 6 years ago

add newlib,libalmos-mkh, restructure shared_syscalls.h and mini-libc

File size: 307 bytes
Line 
1/* Stub version of _exit.  */
2
3#include <limits.h>
4#include "config.h"
5#include <_ansi.h>
6#include <_syslist.h>
7
8void
9_exit (int rc)
10{
11  /* Default stub just causes a divide by 0 exception.  */
12  int x = rc / INT_MAX;
13  x = 4 / x;
14
15  /* Convince GCC that this function never returns.  */
16  for (;;)
17    ;
18}
Note: See TracBrowser for help on using the repository browser.