Nios® II Software Developer Handbook

ID 683525
Date 8/28/2023
Public
Document Table of Contents

15.1.1. _exit()

Prototype

void _exit (int exit_code)

Commonly Called By

newlib C library

Thread-safe

Yes.

Available from ISR

No.

Include

<unistd.h>

Description

The newlib exit() function calls the _exit() function to terminate the current process. Typically, exit() calls this function when main() completes. Because there is only a single process in HAL systems, the HAL implementation blocks forever.

Interrupts are not disabled, so ISRs continue to execute.

The input argument, exit_code, is ignored.

Return

--