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/joinrace.c | 48 ------------------------------------------------ 1 file changed, 48 deletions(-) delete mode 100644 linuxthreads/joinrace.c (limited to 'linuxthreads/joinrace.c') diff --git a/linuxthreads/joinrace.c b/linuxthreads/joinrace.c deleted file mode 100644 index 8e1064c984..0000000000 --- a/linuxthreads/joinrace.c +++ /dev/null @@ -1,48 +0,0 @@ -/* Test case by Permaine Cheung . */ - -#include -#include -#include -#include - -static void * -sub1 (void *arg) -{ - /* Nothing. */ - return NULL; -} - -int -main (void) -{ - int istatus; - int policy; - int cnt; - pthread_t thread1; - struct sched_param spresult1, sp1; - - for (cnt = 0; cnt < 100; ++cnt) - { - printf ("Round %d\n", cnt); - - pthread_create (&thread1, NULL, &sub1, NULL); - pthread_join (thread1, NULL); - - istatus = pthread_getschedparam (thread1, &policy, &spresult1); - if (istatus != ESRCH) - { - printf ("pthread_getschedparam returns: %d\n", istatus); - return 1; - } - - sp1.sched_priority = 0; - istatus = pthread_setschedparam (thread1, SCHED_OTHER, &sp1); - if (istatus != ESRCH) - { - printf ("pthread_setschedparam returns: %d\n", istatus); - return 2; - } - } - - return 0; -} -- cgit v1.2.3-70-g09d2