From 4ecabe5fc23562ee22456c766710a484d077f8bf Mon Sep 17 00:00:00 2001 From: Xiang Xiao Date: Sun, 20 Jun 2021 23:18:01 +0800 Subject: [PATCH] libc/time: Change the type of ls_corr to int_fast32_t since the leap correction is always four bytes in timezone file Signed-off-by: Xiang Xiao Change-Id: I2d72f5eaf37f0c86d95eaf7504a1b8b1469bf06a --- libs/libc/time/lib_localtime.c | 6 +++--- 1 file changed, 3 insertions(+), 3 deletions(-) diff --git a/libs/libc/time/lib_localtime.c b/libs/libc/time/lib_localtime.c index 3e48d2d5dc..e9f2f81236 100644 --- a/libs/libc/time/lib_localtime.c +++ b/libs/libc/time/lib_localtime.c @@ -272,7 +272,7 @@ struct ttinfo_s struct lsinfo_s { /* Leap second information */ time_t ls_trans; /* Transition time */ - int_fast64_t ls_corr; /* Correction to apply */ + int_fast32_t ls_corr; /* Correction to apply */ }; struct state_s @@ -1851,10 +1851,10 @@ static struct tm *timesub(FAR const time_t * const timep, const struct lsinfo_s *lp; time_t tdays; int idays; /* unsigned would be so 2003 */ - int_fast64_t rem; + int_fast32_t rem; int y; FAR const int *ip; - int_fast64_t corr; + int_fast32_t corr; int hit; int i;