summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorgreed-island <[email protected]>2020-03-31 23:54:41 +0800
committerGitHub <[email protected]>2020-03-31 23:54:41 +0800
commit08c15f1b118e1c75f4adbbe983077cb034009fdd (patch)
tree7f410f5b61a8dfb7f4ec965feef9ddb86113980f
parent7f6755c622fd76394f0496752d7b33846f19ebe8 (diff)
Update ipc.c
程序的分支逻辑出错。 详见修改。
-rw-r--r--src/ipc.c5
1 files changed, 5 insertions, 0 deletions
diff --git a/src/ipc.c b/src/ipc.c
index e6955bae37..8e8c4db842 100644
--- a/src/ipc.c
+++ b/src/ipc.c
@@ -1186,6 +1186,11 @@ rt_err_t rt_event_recv(rt_event_t event,
{
/* no waiting */
thread->error = -RT_ETIMEOUT;
+
+ /* enable interrupt */
+ rt_hw_interrupt_enable(level);
+
+ return -RT_ETIMEOUT;
}
else
{