From 0860426d39bba9580fefe88534d35797fa59f8e5 Mon Sep 17 00:00:00 2001 From: Joel Sherrill Date: Wed, 9 Jun 1999 16:46:13 +0000 Subject: Modified to return an error when a bogus return address for the old_priority parameter is provided. --- c/src/exec/rtems/src/tasksetpriority.c | 3 +++ 1 file changed, 3 insertions(+) (limited to 'c') diff --git a/c/src/exec/rtems/src/tasksetpriority.c b/c/src/exec/rtems/src/tasksetpriority.c index f79ad581a5..546ea3d537 100644 --- a/c/src/exec/rtems/src/tasksetpriority.c +++ b/c/src/exec/rtems/src/tasksetpriority.c @@ -61,6 +61,9 @@ rtems_status_code rtems_task_set_priority( !_RTEMS_tasks_Priority_is_valid( new_priority ) ) return RTEMS_INVALID_PRIORITY; + if ( !old_priority ) + return RTEMS_INVALID_ADDRESS; + the_thread = _Thread_Get( id, &location ); switch ( location ) { -- cgit v1.2.3