summaryrefslogtreecommitdiff
path: root/components/libc/compilers/common/stdlib.c
diff options
context:
space:
mode:
authorMeco Jianting Man <[email protected]>2021-02-24 08:01:14 -0600
committerGitHub <[email protected]>2021-02-24 08:01:14 -0600
commitbc28df8b350f2118f418b966df0843c7f2c02496 (patch)
tree9267ab1048a7fa769ccb2af8c074fb06907d3b77 /components/libc/compilers/common/stdlib.c
parentc21f018b4a6ea88e1cbec86514056629a25ccb67 (diff)
parentaaf4696c87514fe14d6da2b502b26ecc1feb2806 (diff)
Merge pull request #20 from RT-Thread/master
pr
Diffstat (limited to 'components/libc/compilers/common/stdlib.c')
-rw-r--r--components/libc/compilers/common/stdlib.c10
1 files changed, 1 insertions, 9 deletions
diff --git a/components/libc/compilers/common/stdlib.c b/components/libc/compilers/common/stdlib.c
index 9f801ab966..48a86098cd 100644
--- a/components/libc/compilers/common/stdlib.c
+++ b/components/libc/compilers/common/stdlib.c
@@ -14,18 +14,10 @@ void __rt_libc_exit(int status)
{
rt_thread_t self = rt_thread_self();
-#ifdef RT_USING_MODULE
- if (dlmodule_self())
- {
- dlmodule_exit(status);
- }
-#endif
-
if (self != RT_NULL)
{
rt_kprintf("thread:%s exit:%d!\n", self->name, status);
- rt_thread_suspend(self);
- rt_schedule();
+ rt_thread_control(self, RT_THREAD_CTRL_CLOSE, RT_NULL);
}
}