diff options
| author | JasonJiaJie <[email protected]> | 2017-12-14 09:12:01 +0800 |
|---|---|---|
| committer | JasonJiaJie <[email protected]> | 2017-12-14 09:12:01 +0800 |
| commit | a2a8e2eee02e30803d813eafdde21a53459c5af9 (patch) | |
| tree | 48c9298e79df107ebbbf532091853c929a3944fd /src/thread.c | |
| parent | bd4c90f61948810278b774a4ba1ad3440c7d1460 (diff) | |
| parent | b0f4ae246a7a0d958777e11ad2392f22f20a99e6 (diff) | |
Merge remote-tracking branch 'upstream/master'
Diffstat (limited to 'src/thread.c')
| -rw-r--r-- | src/thread.c | 5 |
1 files changed, 2 insertions, 3 deletions
diff --git a/src/thread.c b/src/thread.c index c39d689e0f..3a3e55302e 100644 --- a/src/thread.c +++ b/src/thread.c @@ -750,14 +750,13 @@ rt_thread_t rt_thread_find(char *name) struct rt_object *object; struct rt_list_node *node; - extern struct rt_object_information rt_object_container[]; - /* enter critical */ if (rt_thread_self() != RT_NULL) rt_enter_critical(); /* try to find device object */ - information = &rt_object_container[RT_Object_Class_Thread]; + information = rt_object_get_information(RT_Object_Class_Thread); + RT_ASSERT(information != RT_NULL); for (node = information->object_list.next; node != &(information->object_list); node = node->next) |
