diff options
Diffstat (limited to 'testsuites/sptests')
-rw-r--r-- | testsuites/sptests/ChangeLog | 5 | ||||
-rw-r--r-- | testsuites/sptests/sp43/init.c | 18 | ||||
-rw-r--r-- | testsuites/sptests/sp43/sp43.scn | 1 |
3 files changed, 24 insertions, 0 deletions
diff --git a/testsuites/sptests/ChangeLog b/testsuites/sptests/ChangeLog index a3f513db39..54e6e803fd 100644 --- a/testsuites/sptests/ChangeLog +++ b/testsuites/sptests/ChangeLog @@ -1,5 +1,10 @@ 2010-07-27 Joel Sherrill <joel.sherrilL@OARcorp.com> + * sp43/init.c, sp43/sp43.scn: Add code to exercise case where an API + pointer is NULL when getting an object name. + +2010-07-27 Joel Sherrill <joel.sherrilL@OARcorp.com> + * sp11/sp11.scn, sp11/task1.c: Add test case for receiving all events no wait but the condition is only partially satisfied. diff --git a/testsuites/sptests/sp43/init.c b/testsuites/sptests/sp43/init.c index 2bfc5df80c..dc3435db17 100644 --- a/testsuites/sptests/sp43/init.c +++ b/testsuites/sptests/sp43/init.c @@ -473,6 +473,24 @@ rtems_task Init( ); fatal_directive_status( sc, RTEMS_INVALID_ID, "rtems_semaphore_obtain" ); + /* + * Invalid POSIX API pointer on get name + */ + { + void *tmp; + tmp = _Objects_Information_table[OBJECTS_POSIX_API]; + _Objects_Information_table[OBJECTS_POSIX_API] = NULL; + + puts( "rtems_object_get_classic_name - bad API pointer - INVALID_ID" ); + sc = rtems_object_get_classic_name( + rtems_build_id( OBJECTS_POSIX_API, OBJECTS_POSIX_THREADS, 1, 1 ), + &tmpName + ); + fatal_directive_status( sc, RTEMS_INVALID_ID, "object_get_classic_name" ); + + _Objects_Information_table[OBJECTS_POSIX_API] = tmp; + } + puts( "*** END OF TEST 43 ***" ); rtems_test_exit( 0 ); } diff --git a/testsuites/sptests/sp43/sp43.scn b/testsuites/sptests/sp43/sp43.scn index 4b496fe051..37c38026e1 100644 --- a/testsuites/sptests/sp43/sp43.scn +++ b/testsuites/sptests/sp43/sp43.scn @@ -85,4 +85,5 @@ rtems_task_set_priority - clobber internal thread class info rtems_task_set_priority - use valid Idle thread id again rtems_task_set_priority - restore internal thread class info rtems_semaphore_obtain - good but uncreated ID - INVALID_ID - OK +rtems_object_get_classic_name - bad API pointer - INVALID_ID *** END OF TEST 43 *** |