[Kernel] move module tolibc/libdl.

This commit is contained in:
Bernard Xiong
2018-08-30 20:27:45 +08:00
parent 240451b978
commit efe4523132
23 changed files with 1499 additions and 1559 deletions

View File

@@ -11,6 +11,10 @@
#include <pthread.h>
#endif
#ifdef RT_USING_MODULE
#include <dlmodule.h>
#endif
/* Reentrant versions of system calls. */
int
@@ -379,18 +383,12 @@ _free_r (struct _reent *ptr, void *addr)
}
void
_exit (int status)
exit (int status)
{
#ifdef RT_USING_MODULE
rt_module_t module;
module = rt_module_self();
if (module != RT_NULL)
if (dlmodule_self())
{
rt_thread_suspend(rt_thread_self());
/* re-schedule */
rt_schedule();
dlmodule_exit(status);
}
#endif