1 // RUN: %clang_tsan -O1 %s -o %t && %run %t 2>&1 | FileCheck %s
6 static void handler(int, siginfo_t
*, void *) {
7 write(2, "SIGNAL\n", 7);
10 // CHECK-NOT: ThreadSanitizer: signal-unsafe call
14 struct sigaction act
= {};
15 act
.sa_sigaction
= &handler
;
16 act
.sa_flags
= SA_SIGINFO
;
17 sigaction(SIGPROF
, &act
, 0);
19 fprintf(stderr
, "DONE\n");