From a9e81927df6906e563492bc18e068e4184909794 Mon Sep 17 00:00:00 2001 From: Jakob Kaivo Date: Mon, 1 Feb 2021 12:25:35 -0500 Subject: fix conditional on call to waitpid() --- privexec/privexec.c | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/privexec/privexec.c b/privexec/privexec.c index 1b7a54e..4e3816c 100644 --- a/privexec/privexec.c +++ b/privexec/privexec.c @@ -30,7 +30,7 @@ static int check_privileges(char *argv[]) } int status = 1; - if (waitpid(pid, &status, 0) != 0) { + if (waitpid(pid, &status, 0) == -1) { perror(PATH_CHECK); return 1; } -- cgit v1.2.1