What does errno 10 (ECHILD) mean?

 
Could be also:
ConstantTypeOS
ERROR_BAD_ENVIRONMENTWin32 errorWindows
KERN_MEMORY_ERRORKern returnMac
ippStsJPEGMarkerIntel Ipp StatusAny
IRQL_NOT_LESS_OR_EQUALBugCheck CodeWindows
Previous Next
EBADF EAGAIN

ECHILD

What the process state means

ECHILD is returned by the wait family when there is no eligible unwaited child for the request. With waitpid() or waitid(), the selected process can be nonexistent, not a child of the caller, or already collected by another wait path. A process can also lose the expected child relationship when process-management responsibility is delegated to a supervisor or runtime.

This is not the same as “the child is still running”. For a nonblocking wait, that normally has a successful return with no state change, depending on the API and flags. ECHILD instead says there is no child status available to wait for under the requested selection.

How to investigate

  • Track the PID returned by the creation API and the component assigned to reap it.
  • Check whether a signal handler, framework, or parallel control path already called wait.
  • Verify the requested PID and process-parent relationship rather than treating PIDs as globally owned handles.
  • Design shutdown logic so that exactly one owner collects each child status and records its exit result.

References


Looking for a different code? Search another status or error code.