]> CyberLeo.Net >> Repos - FreeBSD/FreeBSD.git/blob - test/msan/Linux/mallinfo.cc
Vendor import of compiler-rt trunk r256633:
[FreeBSD/FreeBSD.git] / test / msan / Linux / mallinfo.cc
1 // RUN: %clangxx_msan -O0 -g %s -o %t && %run %t
2 // REQUIRES: stable-runtime
3
4 #include <assert.h>
5 #include <malloc.h>
6
7 #include <sanitizer/msan_interface.h>
8
9 int main(void) {
10   struct mallinfo mi = mallinfo();
11   assert(__msan_test_shadow(&mi, sizeof(mi)) == -1);
12   return 0;
13 }