summaryrefslogtreecommitdiff
path: root/wilink_6_1/utils
diff options
context:
space:
mode:
Diffstat (limited to 'wilink_6_1/utils')
-rw-r--r--wilink_6_1/utils/timer.c5
1 files changed, 4 insertions, 1 deletions
diff --git a/wilink_6_1/utils/timer.c b/wilink_6_1/utils/timer.c
index f0718a1..d3d10cd 100644
--- a/wilink_6_1/utils/timer.c
+++ b/wilink_6_1/utils/timer.c
@@ -180,14 +180,18 @@ void tmr_ClearInitQueue (TI_HANDLE hTimerModule)
{
TTimerModule *pTimerModule = (TTimerModule *)hTimerModule;
+ context_EnterCriticalSection (pTimerModule->hContext);
while (que_Dequeue (pTimerModule->hInitQueue) != NULL) {}
+ context_LeaveCriticalSection (pTimerModule->hContext);
}
void tmr_ClearOperQueue (TI_HANDLE hTimerModule)
{
TTimerModule *pTimerModule = (TTimerModule *)hTimerModule;
+ context_EnterCriticalSection (pTimerModule->hContext);
while (que_Dequeue (pTimerModule->hOperQueue) != NULL) {}
+ context_LeaveCriticalSection (pTimerModule->hContext);
}
@@ -594,4 +598,3 @@ void tmr_PrintTimer (TI_HANDLE hTimerInfo)
#endif /* TI_DBG */
-