[PATCH] build: Used FAIL_EXIT1 () on failure to exec child [BZ #23990]

Florian Weimer fweimer@redhat.com
Mon May 11 12:14:29 GMT 2020


* Girish Joshi via Libc-alpha:

> diff --git a/support/test-container.c b/support/test-container.c
> index afc23db148..1423320b8a 100644
> --- a/support/test-container.c
> +++ b/support/test-container.c
> @@ -392,7 +392,7 @@ recursive_remove (char *path)
> /* "rm" would have already printed a suitable error message. */
> if (! WIFEXITED (status)
> || WEXITSTATUS (status) != 0)
> - exit (1);
> + FAIL_EXIT1 ("failed to exec child");
> break;
> }

Sorry, this patch arrived corrupted on the list.

The error message is not correct because the child process returned an
error status.  This can mean that execvp failed, or something else.  It
would also make sense to add the status value to the error message.

Thanks,
Florian



More information about the Libc-alpha mailing list