Fixed timer control issue.

git-svn-id: https://rt-thread.googlecode.com/svn/trunk@2323 bbd45198-f89e-11dd-88c7-29a3b14d5316
This commit is contained in:
bernard.xiong@gmail.com 2012-10-08 06:07:52 +00:00
parent c77e211d1d
commit 15b3271d5d
1 changed files with 2 additions and 2 deletions

View File

@ -352,11 +352,11 @@ rt_err_t rt_timer_control(rt_timer_t timer, rt_uint8_t cmd, void *arg)
break;
case RT_TIMER_CTRL_SET_ONESHOT:
timer->parent.flag &= ~(1 << RT_TIMER_FLAG_PERIODIC);
timer->parent.flag &= ~RT_TIMER_FLAG_PERIODIC;
break;
case RT_TIMER_CTRL_SET_PERIODIC:
timer->parent.flag |= (1 << RT_TIMER_FLAG_PERIODIC);
timer->parent.flag |= RT_TIMER_FLAG_PERIODIC;
break;
}