diff options
author | Sebastian Huber <sebastian.huber@embedded-brains.de> | 2021-04-23 08:21:48 +0200 |
---|---|---|
committer | Sebastian Huber <sebastian.huber@embedded-brains.de> | 2021-04-23 08:24:07 +0200 |
commit | f14cf0cd743b6ac128ce5b9007023c57e322500f (patch) | |
tree | 51ebe2ef847497677287af801663bfec9c79281f /cpukit/rtems | |
parent | rtems: Check for NULL config in msgq construct (diff) | |
download | rtems-f14cf0cd743b6ac128ce5b9007023c57e322500f.tar.bz2 |
rtems: Check for NULL config in task construct
Since there are already excessive NULL pointer checks in the Classic
API, do this also in rtems_task_construct().
Update #3959.
Diffstat (limited to 'cpukit/rtems')
-rw-r--r-- | cpukit/rtems/src/taskconstruct.c | 4 |
1 files changed, 4 insertions, 0 deletions
diff --git a/cpukit/rtems/src/taskconstruct.c b/cpukit/rtems/src/taskconstruct.c index a39db3a7ae..e267db2fc5 100644 --- a/cpukit/rtems/src/taskconstruct.c +++ b/cpukit/rtems/src/taskconstruct.c @@ -103,6 +103,10 @@ rtems_status_code rtems_task_construct( rtems_id *id ) { + if ( config == NULL ) { + return RTEMS_INVALID_ADDRESS; + } + return _RTEMS_tasks_Create( config, id, _RTEMS_tasks_Prepare_user_stack ); } |