mirror of
https://github.com/hermitcore/libhermit.git
synced 2025-03-09 00:00:03 +01:00
add check if fork failed
This commit is contained in:
parent
1041ee7ab0
commit
879368a3d0
1 changed files with 3 additions and 0 deletions
|
@ -381,6 +381,9 @@ static int init_qemu(char *path)
|
|||
|
||||
fprintf(stderr, "Didn't find qemu\n");
|
||||
exit(1);
|
||||
} else if (id < 0) {
|
||||
perror("fork");
|
||||
exit(1);
|
||||
}
|
||||
|
||||
// move the parent process to the end of the queue
|
||||
|
|
Loading…
Add table
Reference in a new issue