From 263d856fa4025a727c0556f7fc286f79450d9932 Mon Sep 17 00:00:00 2001 From: Meco Man <920369182@qq.com> Date: Wed, 17 Feb 2021 23:50:12 +0800 Subject: update --- components/libc/compilers/common/stdlib.c | 13 ++++++------- 1 file changed, 6 insertions(+), 7 deletions(-) (limited to 'components/libc/compilers/common/stdlib.c') diff --git a/components/libc/compilers/common/stdlib.c b/components/libc/compilers/common/stdlib.c index 45a65e9c96..b485bbd836 100644 --- a/components/libc/compilers/common/stdlib.c +++ b/components/libc/compilers/common/stdlib.c @@ -9,10 +9,9 @@ */ #include +#include -#define ABORT_STATUS 1 - -void __exit__(int status) +void __rt_libc_exit(int status) { rt_thread_t self = rt_thread_self(); @@ -25,7 +24,7 @@ void __exit__(int status) if (self != RT_NULL) { - if(status == ABORT_STATUS) /* abort() */ + if(status == EXIT_FAILURE) /* abort() */ { rt_kprintf("thread:%s abort!\n", self->name); } @@ -38,12 +37,12 @@ void __exit__(int status) } } -void __abort__(void) +void __rt_libc_abort(void) { - __exit__(ABORT_STATUS); + __rt_libc_exit(EXIT_FAILURE); } -int __system__(const char *string) +int __rt_libc_system(const char *string) { /* TODO */ return 0; -- cgit v1.3.1