1 | // RUN: %clangxx_asan -O0 %s -o %t && %run %t |
---|---|
2 | |
3 | // Regression test for PR17138. |
4 | |
5 | #include <assert.h> |
6 | #include <string.h> |
7 | #include <stdio.h> |
8 | |
9 | int main() { |
10 | char buf[1024]; |
11 | char *res = (char *)strerror_r(errnum: 300, buf: buf, buflen: sizeof(buf)); |
12 | printf(format: "%p\n", res); |
13 | return 0; |
14 | } |
15 |