From a15520db8cecbac0b78f17b1207627e58c2ff9ad Mon Sep 17 00:00:00 2001 From: Craig Small Date: Sat, 3 Mar 2012 11:49:48 +1100 Subject: [PATCH] ps abort causes problems in testsuite Under certain circumstances, using abort() when either make check or make distcheck puts ps into an infinite loop around the function catastrophic_failure() in ps and the C library raise and abort functions. Using exit removes this problem and does almost the same thing. --- ps/global.c | 2 +- testsuite/config/unix.exp | 1 + 2 files changed, 2 insertions(+), 1 deletion(-) diff --git a/ps/global.c b/ps/global.c index 5bddb8c8..11f058e5 100644 --- a/ps/global.c +++ b/ps/global.c @@ -515,5 +515,5 @@ catastrophic_failure(const char *filename, const char *message) { error_at_line(0, 0, filename, linenum, message); - abort(); + exit(EXIT_FAILURE); } diff --git a/testsuite/config/unix.exp b/testsuite/config/unix.exp index 5331b0df..6b95655f 100644 --- a/testsuite/config/unix.exp +++ b/testsuite/config/unix.exp @@ -40,6 +40,7 @@ proc expect_pass { testname reg } { expect { -re "$reg" { pass "$testname" } default { fail "$testname" } + timeout { fail "$testname" } } } -- 2.40.0