mirror of
https://github.com/apache/nuttx.git
synced 2026-09-03 15:43:01 +00:00
irq_csection: fix assert warning
constant 65535 with expression of type 'int16_t' (aka 'short') is always true Signed-off-by: zhuyanlin <zhuyanlin1@xiaomi.com>
This commit is contained in:
parent
7619d2a6f9
commit
0460367a70
1 changed files with 1 additions and 1 deletions
|
|
@ -414,7 +414,7 @@ irqstate_t enter_critical_section(void)
|
|||
* call to enter_critical_section.
|
||||
*/
|
||||
|
||||
DEBUGASSERT(rtcb->irqcount >= 0 && rtcb->irqcount < UINT16_MAX);
|
||||
DEBUGASSERT(rtcb->irqcount >= 0 && rtcb->irqcount < INT16_MAX);
|
||||
if (++rtcb->irqcount == 1)
|
||||
{
|
||||
/* Note that we have entered the critical section */
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue