From 5b1d751f23e87b332b3cb3e86e488fb450abbe1c Mon Sep 17 00:00:00 2001 From: Nikos Mavrogiannopoulos Date: Fri, 13 May 2016 11:28:51 +0200 Subject: tests: avoid calling exit() from signal handlers --- tests/no-signal.c | 3 +-- tests/slow/cipher-test.c | 2 +- tests/slow/hash-large.c | 2 +- 3 files changed, 3 insertions(+), 4 deletions(-) diff --git a/tests/no-signal.c b/tests/no-signal.c index 00a2f040db..2fe2927368 100644 --- a/tests/no-signal.c +++ b/tests/no-signal.c @@ -59,8 +59,7 @@ int main() static void sigpipe(int sig) { - fail("sigpipe received\n"); - exit(1); + _exit(2); } #define BUF_SIZE 64 diff --git a/tests/slow/cipher-test.c b/tests/slow/cipher-test.c index e58cb3562c..6aa5811dc3 100644 --- a/tests/slow/cipher-test.c +++ b/tests/slow/cipher-test.c @@ -23,7 +23,7 @@ int main(int argc, char **argv) static void handle_sigill(int sig) { - exit(0); + _exit(0); } static void tls_log_func(int level, const char *str) diff --git a/tests/slow/hash-large.c b/tests/slow/hash-large.c index 39abb090fc..7c00b9e622 100644 --- a/tests/slow/hash-large.c +++ b/tests/slow/hash-large.c @@ -43,7 +43,7 @@ void doit(void) static void exit_77(int signo) { - exit(77); + _exit(77); } #endif -- cgit v1.2.1