mirror of
https://github.com/RT-Thread/rt-thread.git
synced 2026-09-22 19:44:24 +08:00
Merge pull request #882 from armink/fix_rtservice
[rtservice] Add `rt_list_len` and `rt_slist_len` to rtservice.h .
This commit is contained in:
@@ -49,19 +49,6 @@
|
||||
#include <rtthread.h>
|
||||
#include "finsh.h"
|
||||
|
||||
rt_inline unsigned int rt_list_len(const rt_list_t *l)
|
||||
{
|
||||
unsigned int len = 0;
|
||||
const rt_list_t *p = l;
|
||||
while (p->next != l)
|
||||
{
|
||||
p = p->next;
|
||||
len ++;
|
||||
}
|
||||
|
||||
return len;
|
||||
}
|
||||
|
||||
long hello(void)
|
||||
{
|
||||
rt_kprintf("Hello RT-Thread!\n");
|
||||
|
||||
Reference in New Issue
Block a user