Nios® V Processor Software Developer Handbook

ID 743810
Date 10/12/2024
Public
Document Table of Contents

16.1.1.62. wait()

Prototype

int wait(int *status)

Commonly Called By

newlib C library

Thread-safe

Yes.

Available from ISR

Yes.

Include

<sys/wait.h>

Description

newlib uses the wait() function to wait for all child processes to exit. Because the HAL does not support spawning child processes, this function returns immediately.

Return

On return, the content of status is set to zero, which indicates there is no child processes.

The return value is always –1 and errno is set to ECHILD, which indicates that there are no child processes to wait for.