[ASan/Win] Add a comment about DCL-using-static vs threads
[blocksruntime.git] / test / tsan / thread_leak2.c
blobfc2942b2a05d04c8b36da380a1783b5516f0493e
1 // RUN: %clang_tsan -O1 %s -o %t && %run %t 2>&1 | FileCheck %s
2 #include <pthread.h>
3 #include <stdio.h>
5 void *Thread(void *x) {
6 return 0;
9 int main() {
10 pthread_t t;
11 pthread_create(&t, 0, Thread, 0);
12 pthread_detach(t);
13 printf("PASS\n");
14 return 0;
17 // CHECK-NOT: WARNING: ThreadSanitizer: thread leak