From 0e077c6e42a55a338e1a326aed59977187ea5525 Mon Sep 17 00:00:00 2001 From: Dale Weiler Date: Mon, 26 Aug 2013 13:10:38 -0400 Subject: [PATCH] Fix testsuite for when a process crashes (do not consider it a success) --- test.c | 5 +++-- 1 file changed, 3 insertions(+), 2 deletions(-) diff --git a/test.c b/test.c index d4fd147..6c23dd7 100644 --- a/test.c +++ b/test.c @@ -964,6 +964,7 @@ static void task_destroy(void) { static bool task_trymatch(size_t i, char ***line) { bool success = true; bool process = true; + int retval = EXIT_SUCCESS; FILE *execute; char buffer[4096]; task_template_t *tmpl = task_tasks[i].tmpl; @@ -1094,11 +1095,11 @@ static bool task_trymatch(size_t i, char ***line) { } if (process) - pclose(execute); + retval = pclose(execute); else fs_file_close(execute); - return success; + return success && retval == EXIT_SUCCESS; } static const char *task_type(task_template_t *tmpl) { -- 2.39.2