summaryrefslogtreecommitdiffstats
path: root/cpukit/posix/src/pthread.c
diff options
context:
space:
mode:
authorSebastian Huber <sebastian.huber@embedded-brains.de>2015-06-13 15:29:04 +0200
committerSebastian Huber <sebastian.huber@embedded-brains.de>2015-06-13 15:51:21 +0200
commit80fca28198170a84cde8a9f22dbb29c3a6c4123b (patch)
treeacea5eb27023816bd447d6fe004f8f00a7830d1e /cpukit/posix/src/pthread.c
parentscore: Delete unused state WATCHDOG_REMOVE_IT (diff)
downloadrtems-80fca28198170a84cde8a9f22dbb29c3a6c4123b.tar.bz2
score: Add _Watchdog_Preinitialize()
Add an assert to ensure that the watchdog is the proper state for a _Watchdog_Initialize(). This helps to detect invalid initializations which may lead to a corrupt watchdog chain.
Diffstat (limited to 'cpukit/posix/src/pthread.c')
-rw-r--r--cpukit/posix/src/pthread.c1
1 files changed, 1 insertions, 0 deletions
diff --git a/cpukit/posix/src/pthread.c b/cpukit/posix/src/pthread.c
index 6395ec0ebd..02d86b5536 100644
--- a/cpukit/posix/src/pthread.c
+++ b/cpukit/posix/src/pthread.c
@@ -241,6 +241,7 @@ static bool _POSIX_Threads_Create_extension(
_Thread_queue_Initialize( &api->Join_List, THREAD_QUEUE_DISCIPLINE_FIFO );
+ _Watchdog_Preinitialize( &api->Sporadic_timer );
_Watchdog_Initialize(
&api->Sporadic_timer,
_POSIX_Threads_Sporadic_budget_TSR,