1 // Test for cleanups with pthread_cancel.
4 // { dg-require-effective-target c++11 }
5 // { dg-require-effective-target tls_runtime }
6 // { dg-require-effective-target pthread }
7 // { dg-require-effective-target non_bionic }
8 // { dg-options -pthread }
9 // { dg-add-options tls }
27 void *thread_main(void *)
40 pthread_create (&thread, 0, thread_main, 0);
41 pthread_cancel(thread);
42 pthread_join(thread, 0);
43 pthread_create (&thread, 0, thread_main, 0);
44 pthread_cancel(thread);
45 pthread_join(thread, 0);