mirror of https://github.com/RT-Thread/rt-thread
parent
c49c5a4d06
commit
8da744a750
|
@ -20,16 +20,18 @@ void __rt_libc_exit(int status)
|
||||||
|
|
||||||
if (self != RT_NULL)
|
if (self != RT_NULL)
|
||||||
{
|
{
|
||||||
|
LOG_W("thread:%s exit:%d!", self->name, status);
|
||||||
#ifdef RT_USING_PTHREADS
|
#ifdef RT_USING_PTHREADS
|
||||||
if(self->pthread_data != RT_NULL)
|
if(self->pthread_data != RT_NULL)
|
||||||
{
|
{
|
||||||
extern void pthread_exit(void *value);
|
extern void pthread_exit(void *value);
|
||||||
pthread_exit((void *)status);
|
pthread_exit((void *)status);
|
||||||
}
|
}
|
||||||
#else
|
else
|
||||||
LOG_E("thread:%s exit:%d!", self->name, status);
|
|
||||||
rt_thread_control(self, RT_THREAD_CTRL_CLOSE, RT_NULL);
|
|
||||||
#endif
|
#endif
|
||||||
|
{
|
||||||
|
rt_thread_control(self, RT_THREAD_CTRL_CLOSE, RT_NULL);
|
||||||
|
}
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
|
|
Loading…
Reference in New Issue