1 // RUN: %clangxx_asan -O0 %s -o %t && not %run %t 2>&1 | FileCheck %s
2 // RUN: %clangxx_asan -O3 %s -o %t && not %run %t 2>&1 | FileCheck %s
4 // UNSUPPORTED: darwin, aarch64
11 int main(int argc
, char **argv
) {
15 int *status
= x
+ argc
* 3;
18 siginfo_t
*si
= (siginfo_t
*)(x
+ argc
* 3);
19 res
= waitid(P_ALL
, 0, si
, WEXITED
| WNOHANG
);
20 // CHECK: stack-buffer-overflow
21 // CHECK: {{WRITE of size .* at 0x.* thread T0}}
22 // CHECK: {{in .*waitid}}
23 // CHECK: {{in main .*waitid.cpp:}}
24 // CHECK: is located in stack of thread T0 at offset