about summary refs log tree commit diff
path: root/sysdeps
diff options
context:
space:
mode:
authorAdhemerval Zanella <adhemerval.zanella@linaro.org>2024-02-14 17:33:41 +0000
committerAdhemerval Zanella <adhemerval.zanella@linaro.org>2024-03-27 13:47:09 -0300
commit2e53eb923486704b7a0d6f3d81d1ee8ba672a56b (patch)
treec5aaa66e75287df3deee76b16b0347db8344965d /sysdeps
parent96d1b9ac2321b565f340ba8f3674597141e3450d (diff)
downloadglibc-2e53eb923486704b7a0d6f3d81d1ee8ba672a56b.tar.gz
glibc-2e53eb923486704b7a0d6f3d81d1ee8ba672a56b.tar.xz
glibc-2e53eb923486704b7a0d6f3d81d1ee8ba672a56b.zip
signal: Avoid system signal disposition to interfere with tests
Both tst-sigset2 and tst-signal1 expectes that SIGINT disposition
is set to SIG_DFL.
Diffstat (limited to 'sysdeps')
-rw-r--r--sysdeps/pthread/tst-signal1.c3
1 files changed, 3 insertions, 0 deletions
diff --git a/sysdeps/pthread/tst-signal1.c b/sysdeps/pthread/tst-signal1.c
index 1c550ef8eb..ca145eef3d 100644
--- a/sysdeps/pthread/tst-signal1.c
+++ b/sysdeps/pthread/tst-signal1.c
@@ -26,6 +26,7 @@
 #include <sys/wait.h>
 
 #include <support/xunistd.h>
+#include <support/xsignal.h>
 
 static sigset_t ss;
 static pthread_barrier_t *b;
@@ -93,6 +94,8 @@ receiver (void)
 static int
 do_test (void)
 {
+  xsignal (SIGINT, SIG_DFL);
+
   char tmp[] = "/tmp/tst-signal1-XXXXXX";
 
   int fd = mkstemp (tmp);