diff options
Diffstat (limited to 'pthread_getschedparam.c')
| -rw-r--r-- | pthread_getschedparam.c | 6 | 
1 files changed, 4 insertions, 2 deletions
diff --git a/pthread_getschedparam.c b/pthread_getschedparam.c index 081bfe3..125999a 100644 --- a/pthread_getschedparam.c +++ b/pthread_getschedparam.c @@ -43,11 +43,13 @@ pthread_getschedparam(pthread_t thread, int *policy,  			  struct sched_param *param)  {    int prio; +  int result;    /* Validate the thread id. */ -  if (thread == NULL || thread->threadH == 0) +  result = pthread_kill(thread, 0); +  if (0 != result)      { -      return ESRCH; +      return result;      }    /*  | 
