1 /* Test that all threads are killed when exit() is called. */
8 void *thread_proc(void *arg
)
10 /* Wait for main thread to block. */
13 /* Exit the program. */
24 if (pthread_create(&thread
, NULL
, thread_proc
, NULL
)) {
25 perror("pthread_create");
29 if (pthread_join(thread
, &status
)) {
30 perror("pthread_join");
34 /* This code should not be reached. */
35 fprintf(stderr
, "Thread joined\n");