diff options
Diffstat (limited to 'src/thread.c')
| -rw-r--r-- | src/thread.c | 10 |
1 files changed, 5 insertions, 5 deletions
diff --git a/src/thread.c b/src/thread.c index 5614edea4d..56f9094ab0 100644 --- a/src/thread.c +++ b/src/thread.c @@ -237,7 +237,7 @@ static rt_err_t _thread_init(struct rt_thread *thread, /* initialize thread timer */ rt_timer_init(&(thread->thread_timer), - thread->name, + thread->parent.name, _thread_timeout, thread, 0, @@ -274,7 +274,7 @@ static rt_err_t _thread_init(struct rt_thread *thread, #endif /* RT_USING_PTHREADS */ #ifdef RT_USING_MODULE - thread->module_id = 0; + thread->parent.module_id = 0; #endif /* RT_USING_MODULE */ RT_OBJECT_HOOK_CALL(rt_thread_inited_hook, (thread)); @@ -386,7 +386,7 @@ rt_err_t rt_thread_startup(rt_thread_t thread) #endif /* RT_THREAD_PRIORITY_MAX > 32 */ RT_DEBUG_LOG(RT_DEBUG_THREAD, ("startup a thread:%s with priority:%d\n", - thread->name, thread->current_priority)); + thread->parent.name, thread->current_priority)); /* change thread stat */ thread->stat = RT_THREAD_SUSPEND; /* then resume it */ @@ -983,7 +983,7 @@ rt_err_t rt_thread_suspend_with_flag(rt_thread_t thread, int suspend_flag) RT_ASSERT(rt_object_get_type((rt_object_t)thread) == RT_Object_Class_Thread); RT_ASSERT(thread == rt_thread_self()); - RT_DEBUG_LOG(RT_DEBUG_THREAD, ("thread suspend: %s\n", thread->name)); + RT_DEBUG_LOG(RT_DEBUG_THREAD, ("thread suspend: %s\n", thread->parent.name)); stat = thread->stat & RT_THREAD_STAT_MASK; if ((stat != RT_THREAD_READY) && (stat != RT_THREAD_RUNNING)) @@ -1046,7 +1046,7 @@ rt_err_t rt_thread_resume(rt_thread_t thread) RT_ASSERT(thread != RT_NULL); RT_ASSERT(rt_object_get_type((rt_object_t)thread) == RT_Object_Class_Thread); - RT_DEBUG_LOG(RT_DEBUG_THREAD, ("thread resume: %s\n", thread->name)); + RT_DEBUG_LOG(RT_DEBUG_THREAD, ("thread resume: %s\n", thread->parent.name)); if ((thread->stat & RT_THREAD_SUSPEND_MASK) != RT_THREAD_SUSPEND_MASK) { |
