forked from Imagelibrary/rtems
@@ -41,6 +41,10 @@ rtems_status_code rtems_task_start(
|
||||
ISR_lock_Context lock_context;
|
||||
bool ok;
|
||||
|
||||
if ( entry_point == NULL ) {
|
||||
return RTEMS_INVALID_ADDRESS;
|
||||
}
|
||||
|
||||
the_thread = _Thread_Get( id, &lock_context );
|
||||
|
||||
if ( the_thread == NULL ) {
|
||||
|
||||
@@ -165,6 +165,15 @@ rtems_task Task_1(
|
||||
);
|
||||
puts( "TA1 - rtems_task_start - RTEMS_INVALID_ID" );
|
||||
|
||||
/* NULL entry point */
|
||||
status = rtems_task_start( RTEMS_SELF, NULL, 0 );
|
||||
fatal_directive_status(
|
||||
status,
|
||||
RTEMS_INVALID_ADDRESS,
|
||||
"rtems_task_start with NULL entry point"
|
||||
);
|
||||
puts( "TA1 - rtems_task_start - RTEMS_INVALID_ADDRESS" );
|
||||
|
||||
/* already started */
|
||||
status = rtems_task_start( RTEMS_SELF, Task_1, 0 );
|
||||
fatal_directive_status(
|
||||
|
||||
Reference in New Issue
Block a user