lib/drmtest: Improve output when igt_waitchildren fails

Signed-off-by: Daniel Vetter <daniel.vetter@ffwll.ch>
This commit is contained in:
Daniel Vetter 2013-09-02 08:08:29 +02:00
parent 8eaa0982d0
commit 6f118bf96a

View File

@ -1001,17 +1001,21 @@ void igt_waitchildren(void)
; ;
if (status != 0) { if (status != 0) {
if (WIFEXITED(status)) if (WIFEXITED(status)) {
printf("child %i failed with exit status %i\n",
nc, WEXITSTATUS(status));
igt_fail(WEXITSTATUS(status)); igt_fail(WEXITSTATUS(status));
else if (WIFSIGNALED(status)) { } else if (WIFSIGNALED(status)) {
printf("child %i died with signal %i, %s\n", printf("child %i died with signal %i, %s\n",
nc, WTERMSIG(status), nc, WTERMSIG(status),
strsignal(WTERMSIG(status))); strsignal(WTERMSIG(status)));
igt_fail(99); igt_fail(99);
} else } else {
printf("Unhandled failure in child %i\n", nc);
abort(); abort();
} }
} }
}
num_test_children = 0; num_test_children = 0;
} }