提交 c9de2b44 编写于 作者: X x_xiny

fix:...

fix: L1-liteos-tdd测试liteos_a_process_unittest.bin,liteos_a_security_vid_unittest.bin和liteos_a_time_clock_unittest.bin模块用例un

【背景】L1-liteos-tdd测试liteos_a_process_unittest.bin,liteos_a_security_vid_unittest.bin和liteos_a_time_clock_unittest.bin模块用例un

【修改方案】
 1.暂时将musl中的exit()接口中的原子操作改为使用mutex方式实现
 2.删除内核中不必要的打印

re #I4K9A5
Signed-off-by: Nxuiny <xuxinyu6@huawei.com>
Change-Id: I1a0e41febe69e6e25efb53bdf8d070824ad9b9fe
上级 61d3e75b
......@@ -4,11 +4,13 @@
#include <debug.h>
#include <signal.h>
#include <atomic.h>
#include <pthread.h>
#include "libc.h"
extern bool g_enable_check;
extern void mem_check_deinit(void);
extern void clean_recycle_list(bool clean_all);
pthread_mutex_t __exit_mutex = PTHREAD_MUTEX_INITIALIZER;
static void dummy()
{
......@@ -35,9 +37,9 @@ weak_alias(libc_exit_fini, __libc_exit_fini);
_Noreturn void exit(int code)
{
sigset_t set;
if (a_cas(&libc.exit, 0, 1) != 0) {
return;
}
pthread_mutex_lock(&__exit_mutex);
__block_app_sigs(&set);
if (g_enable_check) {
check_leak();
......
Markdown is supported
0% .
You are about to add 0 people to the discussion. Proceed with caution.
先完成此消息的编辑!
想要评论请 注册