Minishell
Loading...
Searching...
No Matches
wait_child.c File Reference
#include <stdlib.h>
#include <string.h>
#include <sys/wait.h>
#include "../include/main.h"
Include dependency graph for wait_child.c:

Functions

void wait_child (int cpid, data_t *data)
 

Function Documentation

◆ wait_child()

void wait_child ( int cpid,
data_t * data )

This function waits for the executed command to finish and prints any error that could have happened also it will save its exit status code on data->status

Parameters
cpidChild process id
dataGlobal data structure
Here is the call graph for this function: