forked from Imagelibrary/rtems
2000-12-19 Joel Sherrill <joel@OARcorp.com>
* src/pthreadgetschedparam.c: Do not set output parameters if the pointers are NULL.
This commit is contained in:
@@ -1,3 +1,8 @@
|
||||
2000-12-19 Joel Sherrill <joel@OARcorp.com>
|
||||
|
||||
* src/pthreadgetschedparam.c: Do not set output parameters if
|
||||
the pointers are NULL.
|
||||
|
||||
2000-12-06 Joel Sherrill <joel@OARcorp.com>
|
||||
|
||||
* src/pthreadgetcpuclockid.c: Add include of <rtems/system.h> to
|
||||
|
||||
@@ -40,10 +40,13 @@ int pthread_getschedparam(
|
||||
return ESRCH;
|
||||
case OBJECTS_LOCAL:
|
||||
api = the_thread->API_Extensions[ THREAD_API_POSIX ];
|
||||
if ( policy )
|
||||
*policy = api->schedpolicy;
|
||||
if ( param ) {
|
||||
*param = api->schedparam;
|
||||
param->sched_priority =
|
||||
_POSIX_Priority_From_core( the_thread->current_priority );
|
||||
}
|
||||
_Thread_Enable_dispatch();
|
||||
return 0;
|
||||
}
|
||||
|
||||
@@ -1,3 +1,8 @@
|
||||
2000-12-19 Joel Sherrill <joel@OARcorp.com>
|
||||
|
||||
* src/pthreadgetschedparam.c: Do not set output parameters if
|
||||
the pointers are NULL.
|
||||
|
||||
2000-12-06 Joel Sherrill <joel@OARcorp.com>
|
||||
|
||||
* src/pthreadgetcpuclockid.c: Add include of <rtems/system.h> to
|
||||
|
||||
@@ -40,10 +40,13 @@ int pthread_getschedparam(
|
||||
return ESRCH;
|
||||
case OBJECTS_LOCAL:
|
||||
api = the_thread->API_Extensions[ THREAD_API_POSIX ];
|
||||
if ( policy )
|
||||
*policy = api->schedpolicy;
|
||||
if ( param ) {
|
||||
*param = api->schedparam;
|
||||
param->sched_priority =
|
||||
_POSIX_Priority_From_core( the_thread->current_priority );
|
||||
}
|
||||
_Thread_Enable_dispatch();
|
||||
return 0;
|
||||
}
|
||||
|
||||
Reference in New Issue
Block a user