From 0ecb606cb6cf65de1d9fc8a919bceb4be476c602 Mon Sep 17 00:00:00 2001 From: Jakub Jelinek Date: Thu, 12 Jul 2007 18:26:36 +0000 Subject: 2.5-18.1 --- linuxthreads/bug-sleep.c | 34 ---------------------------------- 1 file changed, 34 deletions(-) delete mode 100644 linuxthreads/bug-sleep.c (limited to 'linuxthreads/bug-sleep.c') diff --git a/linuxthreads/bug-sleep.c b/linuxthreads/bug-sleep.c deleted file mode 100644 index f29a6b73c0..0000000000 --- a/linuxthreads/bug-sleep.c +++ /dev/null @@ -1,34 +0,0 @@ -/* PR libc/4005 */ -#include -#include -#include -#include - -void * -run_thread (void *a) -{ - while (1) - { - sleep (10); - } - return 0; -} - -int -main (void) -{ - pthread_t thr; - void *result; - alarm (4); - printf ("Starting thread.\n"); - pthread_create (&thr, 0, run_thread, 0); - sleep (2); - printf ("Canceling thread.\n"); - pthread_cancel (thr); - pthread_join (thr, &result); - if (result == PTHREAD_CANCELED) - printf ("Thread canceled.\n"); - else - printf ("Thread exited.\n"); - return 0; -} -- cgit v1.2.3