rootless: drop preexec hook error message

the exec hooks already print the error message, so there is no need to
print another one.

[NO NEW TESTS NEEDED]

Signed-off-by: Giuseppe Scrivano <gscrivan@redhat.com>
This commit is contained in:
Giuseppe Scrivano
2023-03-31 09:34:35 +02:00
parent 3e44a7afed
commit 266cc78829

View File

@ -163,20 +163,11 @@ exec_binary (const char *path, char **argv, int argc)
exit (EXIT_FAILURE); exit (EXIT_FAILURE);
} }
if (WIFEXITED(status) && WEXITSTATUS (status)) if (WIFEXITED(status) && WEXITSTATUS (status))
{ exit (WEXITSTATUS(status));
fprintf (stderr, "external preexec hook %s failed\n", path);
exit (WEXITSTATUS(status));
}
if (WIFSIGNALED (status)) if (WIFSIGNALED (status))
{ exit (127+WTERMSIG (status));
fprintf (stderr, "external preexec hook %s failed\n", path);
exit (127+WTERMSIG (status));
}
if (WIFSTOPPED (status)) if (WIFSTOPPED (status))
{
fprintf (stderr, "external preexec hook %s failed\n", path);
exit (EXIT_FAILURE); exit (EXIT_FAILURE);
}
} }
static void static void