diff options
| author | JP Appel <jeanpierre.appel01@gmail.com> | 2025-10-03 23:13:45 -0400 |
|---|---|---|
| committer | JP Appel <jeanpierre.appel01@gmail.com> | 2025-10-03 23:13:45 -0400 |
| commit | e033b0fb1c2b90cb7e744bf9972f42b18b683eb6 (patch) | |
| tree | ce07675430cb50ea3102e5ad17c9d3b31666c8fb /eztester_list.c | |
| parent | a033103e60aca0c17afa6117e8e46b197aa90109 (diff) | |
Redirect stdout and stderr from worker process to a temporary file.
The temporary files are printed for premature exits or test failures.
Diffstat (limited to 'eztester_list.c')
| -rw-r--r-- | eztester_list.c | 13 |
1 files changed, 5 insertions, 8 deletions
diff --git a/eztester_list.c b/eztester_list.c index 42ebcbc..bef449b 100644 --- a/eztester_list.c +++ b/eztester_list.c @@ -43,13 +43,10 @@ void ez_register(ez_list *test_list, const ez_test new_test) { test_list->tests[test_list->length++] = new_test; } -void ez_clear_list(ez_list *test_list) { - free(test_list->tests); - test_list->length = 0; - test_list->capacity = 0; -} +void ez_clear_list(ez_list *test_list) { test_list->length = 0; } -void ez_destroy_list(ez_list *test_list) { - ez_clear_list(test_list); - free(test_list); +void ez_destroy_list(ez_list *list) { + ez_clear_list(list); + list->capacity = 0; + free(list->tests); } |
