diff options
author | Sebastian Huber <sebastian.huber@embedded-brains.de> | 2017-10-17 10:06:08 +0200 |
---|---|---|
committer | Sebastian Huber <sebastian.huber@embedded-brains.de> | 2017-10-17 10:12:10 +0200 |
commit | 2fcea4c47325578d887d2c061a86e5e178d7a32a (patch) | |
tree | f779f8268a4a25365d4509ba082ab9f1204b2c2b /testsuites/psxtests | |
parent | score: Rename _Watchdog_Per_CPU_insert_monotonic() (diff) | |
download | rtems-2fcea4c47325578d887d2c061a86e5e178d7a32a.tar.bz2 |
posix: Fix _POSIX_Threads_Create_extension()
The thread POSIX API control must be fully initialized in
_POSIX_Threads_Create_extension(), otherwise a pthread_setschedparam()
is broken for all threads not created with pthread_create().
Diffstat (limited to 'testsuites/psxtests')
-rw-r--r-- | testsuites/psxtests/psxclassic01/init.c | 8 |
1 files changed, 8 insertions, 0 deletions
diff --git a/testsuites/psxtests/psxclassic01/init.c b/testsuites/psxtests/psxclassic01/init.c index 924224c7b7..1acc14142a 100644 --- a/testsuites/psxtests/psxclassic01/init.c +++ b/testsuites/psxtests/psxclassic01/init.c @@ -52,9 +52,17 @@ rtems_task test_task(rtems_task_argument arg) int sc; struct sigaction new_action; sigset_t mask; + int policy; + struct sched_param param; printf("test_task starting...\n"); + sc = pthread_getschedparam( pthread_self(), &policy, ¶m ); + rtems_test_assert( sc == 0 ); + + sc = pthread_setschedparam( pthread_self(), policy, ¶m ); + rtems_test_assert( sc == 0 ); + sc = sigemptyset (&new_action.sa_mask); rtems_test_assert( sc == 0 ); |