1 // RUN: %clangxx_msan -O0 %s -o %t && %run %t 2>&1
2 // RUN: %clangxx_msan -O0 -D_FILE_OFFSET_BITS=64 %s -o %t && %run %t 2>&1
3 // RUN: %clangxx_msan -O3 %s -o %t && %run %t 2>&1
11 #include <sanitizer/msan_interface.h>
13 int main(int argc
, char *argv
[]) {
14 char ifname
[IF_NAMESIZE
+ 1];
15 assert(0 == __msan_test_shadow(ifname
, sizeof(ifname
)));
16 if (!if_indextoname(1, ifname
)) {
17 assert(errno
== ENXIO
);
18 printf("No network interfaces found.\n");
21 assert(strlen(ifname
) + 1 <= __msan_test_shadow(ifname
, sizeof(ifname
)));