poprawka
This commit is contained in:
parent
80b80511a5
commit
1162dc72aa
@ -52,8 +52,11 @@ int main (){
|
|||||||
else if (!strcmp(argv[0], "exit"))
|
else if (!strcmp(argv[0], "exit"))
|
||||||
break;
|
break;
|
||||||
else
|
else
|
||||||
if (fork() == 0)
|
if (fork() == 0){
|
||||||
execvp(argv[0], argv);
|
execvp(argv[0], argv);
|
||||||
|
perror("execvp");
|
||||||
|
exit(EXIT_FAILURE);
|
||||||
|
}
|
||||||
else
|
else
|
||||||
wait(NULL);
|
wait(NULL);
|
||||||
|
|
||||||
|
Loading…
Reference in New Issue
Block a user