1 // Checks if a user pointer is found by the leak sanitizer. 2 // RUN: %clang_lsan %s -o %t 3 // RUN: %run %t 2>&1 4 5 #include <stdint.h> 6 #include <stdio.h> 7 #include <stdlib.h> 8 9 uintptr_t glob[1024]; 10 main()11int main() { 12 for (int i = 0; i < 1024; ++i) { 13 // Check that the pointers will not be falsely reported as leaks. 14 glob[i] = (uintptr_t)malloc(sizeof(int *)); 15 } 16 return 0; 17 } 18