[rtems commit] score: Fix warning

Sebastian Huber sebh at rtems.org
Wed Feb 15 12:06:25 UTC 2017


Module:    rtems
Branch:    master
Commit:    7a462cc60d5361131a8844d79d1bcbc10bb6fc2e
Changeset: http://git.rtems.org/rtems/commit/?id=7a462cc60d5361131a8844d79d1bcbc10bb6fc2e

Author:    Sebastian Huber <sebastian.huber at embedded-brains.de>
Date:      Wed Feb 15 11:09:32 2017 +0100

score: Fix warning

---

 cpukit/score/src/threadinitialize.c | 2 ++
 1 file changed, 2 insertions(+)

diff --git a/cpukit/score/src/threadinitialize.c b/cpukit/score/src/threadinitialize.c
index 2eb6507..c34113d 100644
--- a/cpukit/score/src/threadinitialize.c
+++ b/cpukit/score/src/threadinitialize.c
@@ -185,6 +185,7 @@ bool _Thread_Initialize(
   }
 
 #if defined(RTEMS_SMP)
+  scheduler_node = NULL;
   scheduler_node_for_index = the_thread->Scheduler.nodes;
   scheduler_for_index = &_Scheduler_Table[ 0 ];
 
@@ -217,6 +218,7 @@ bool _Thread_Initialize(
     ++scheduler_index;
   }
 
+  _Assert( scheduler_node != NULL );
   _Chain_Initialize_one(
     &the_thread->Scheduler.Wait_nodes,
     &scheduler_node->Thread.Wait_node



More information about the vc mailing list