Crate nstd_proc

Source

Functions§

nstd_proc_abort
Terminates the program in an abnormal fashion.
nstd_proc_exit
Exits the program with the specified exit code. Parameters: const int code - The exit code.
nstd_proc_free
Frees memory allocated by nstd_proc_spawn. Parameters: NSTDChildProcess *handle - Pointer to a process handle.
nstd_proc_id
Gets the current process’ ID. Returns: NSTDProcessID id - The process ID.
nstd_proc_kill
Kills a process by it’s handle. Does not free memory allocated by nstd_proc_spawn. Parameters: NSTDChildProcess handle - The handle to the process. Returns: int errc - Nonzero on error.
nstd_proc_pid
Gets the ID of a process by handle. Parameters: NSTDChildProcess handle - The handle to the process. Returns: NSTDProcessID id - The process ID.
nstd_proc_spawn
Starts a new process. Parameters: const char *const name - The name of the process. const char *args - String array of arguments to pass to the process. const NSTDUSize size - The number of args to pass. Returns: NSTDChildProcess handle - The handle to the new process, null on error.
nstd_proc_wait
Waits for a process to finish. Does not free memory allocated by nstd_proc_spawn. Parameters: NSTDChildProcess handle - The handle to the process. int *code - The exit code from the process, set to null if there was none specified.

Type Aliases§

NSTDChildProcess
Represents a process handle returned by nstd_proc_spawn.
NSTDProcessID
Represents a process ID.