summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorshaojinchun <[email protected]>2019-09-17 11:02:34 +0800
committershaojinchun <[email protected]>2019-09-17 11:02:34 +0800
commit770cc2ffeb1803ad3859d6ba90c895180a4e07d7 (patch)
treebf024dd47b3663512aaba4084afba2aa04113f2f
parentae1fdc70f0086c0e12bfe02c9b69153e7743dc22 (diff)
修改mempool使用rt_list_for_each宏进行遍历
-rw-r--r--components/finsh/cmd.c2
1 files changed, 1 insertions, 1 deletions
diff --git a/components/finsh/cmd.c b/components/finsh/cmd.c
index f8b774bd6f..a283c4f2c5 100644
--- a/components/finsh/cmd.c
+++ b/components/finsh/cmd.c
@@ -691,7 +691,7 @@ long list_mempool(void)
mp = (struct rt_mempool *)obj;
suspend_thread_count = 0;
- for (node = mp->suspend_thread.next; node != &mp->suspend_thread; node = node->next)
+ rt_list_for_each(node, &mp->suspend_thread)
{
suspend_thread_count++;
}