Initialize timer magic number.
authorbatt <batt@38d2e660-2303-0410-9eaa-f027e97ec537>
Wed, 16 Feb 2011 18:21:40 +0000 (18:21 +0000)
committerbatt <batt@38d2e660-2303-0410-9eaa-f027e97ec537>
Wed, 16 Feb 2011 18:21:40 +0000 (18:21 +0000)
There is a (very low) chance that the stack memory
contains the wrong magic number causing ASSERTs to fire.

git-svn-id: https://src.develer.com/svnoss/bertos/trunk@4708 38d2e660-2303-0410-9eaa-f027e97ec537

bertos/drv/timer.c

index d75f15abcf85324e525444bd3ad060404f196c56..e3043da49a7014f5294a138081d5825dc9cff8e6 100644 (file)
@@ -252,7 +252,7 @@ void timer_delayTicks(ticks_t delay)
 
 #if CONFIG_KERN_SIGNALS
        Timer t;
-
+       DB(t.magic = TIMER_MAGIC_INACTIVE;)
        if (proc_preemptAllowed())
        {
                ASSERT(!sig_check(SIG_SINGLE));