minix3/kernel/system/do_exit.c

28 lines
643 B
C
Raw Normal View History

2020-02-21 00:59:27 +05:30
/* The kernel call implemented in this file:
* m_type: SYS_EXIT
*/
#include "kernel/system.h"
#include <signal.h>
#if USE_EXIT
/*===========================================================================*
* do_exit *
*===========================================================================*/
int do_exit(struct proc * caller, message * m_ptr)
{
/* Handle sys_exit. A system process has requested to exit. Generate a
* self-termination signal.
*/
int sig_nr = SIGABRT;
cause_sig(caller->p_nr, sig_nr); /* send a signal to the caller */
return(EDONTREPLY); /* don't reply */
}
#endif /* USE_EXIT */