1 // RUN: %clangxx_msan -O0 %s -o %t && %run %t
4 #include <sys/socket.h>
8 void poison_stack_ahead() {
10 // With -O0 this poisons a large chunk of stack.
18 // This should trigger loading of libnss_dns and friends.
19 // Those libraries are typically uninstrumented.They will call strlen() on a
20 // stack-allocated buffer, which is very likely to be poisoned. Test that we
21 // don't report this as an UMR.
22 int res
= getaddrinfo("not-in-etc-hosts", NULL
, NULL
, &ai
);