[ptest-runner,2/2] utils.c: Print DURATION after ERROR
Submitted by Aníbal Limón on Jan. 30, 2019, 5:07 p.m.
|
Patch ID: 158393
Details
Commit Message
@@ -382,12 +382,12 @@ run_ptests(struct ptest_list *head, const struct ptest_options opts,
opts.timeout, fds, fps, &timeouted);
entime = time(NULL);
duration = entime - sttime;
- fprintf(fps[0], "DURATION: %d\n", duration);
if (status) {
fprintf(fps[0], "\nERROR: Exit status is %d\n", status);
rc += 1;
}
+ fprintf(fps[0], "DURATION: %d\n", duration);
if (timeouted)
fprintf(fps[0], "TIMEOUT: %s\n", ptest_dir);
If a process gets killed by timeout or OOM the output could end without '\n' so add 'DURATION: N\n' after '\nERROR: ptest-dir\n'. Signed-off-by: Aníbal Limón <anibal.limon@linaro.org> --- utils.c | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-)