From a924da830e0105c981bef650cb1391e9580e819d Mon Sep 17 00:00:00 2001 From: Meco Man <920369182@qq.com> Date: Sun, 17 Jul 2022 02:58:43 -0400 Subject: [PATCH] =?UTF-8?q?[libc]=20=E4=BF=AE=E5=A4=8Ddifftime=E5=87=BD?= =?UTF-8?q?=E6=95=B0=E5=9C=A8IAR=E4=B8=8B=E7=9A=84=E7=BC=96=E8=AF=91?= =?UTF-8?q?=E9=94=99=E8=AF=AF?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- components/libc/compilers/common/ctime.c | 2 ++ 1 file changed, 2 insertions(+) diff --git a/components/libc/compilers/common/ctime.c b/components/libc/compilers/common/ctime.c index 6cef1e222d..34d646ff9d 100644 --- a/components/libc/compilers/common/ctime.c +++ b/components/libc/compilers/common/ctime.c @@ -324,10 +324,12 @@ char* ctime(const time_t *tim_p) } RTM_EXPORT(ctime); +#ifndef __ICCARM__ double difftime(time_t time1, time_t time2) { return (double)(time1 - time2); } +#endif /* __ICCARM__ */ RTM_EXPORT(difftime); RTM_EXPORT(strftime); /* inherent in the toolchain */