This is an automated email from the ASF dual-hosted git repository.
xiaoxiang pushed a commit to branch master
in repository https://gitbox.apache.org/repos/asf/nuttx-apps.git
The following commit(s) were added to refs/heads/master by this push:
new 3f08d4f11 rtc: change localtime to gmtime.
3f08d4f11 is described below
commit 3f08d4f11c4fab5ebb943d709942443a7d9daacb
Author: yangguangcai <[email protected]>
AuthorDate: Tue Jul 4 19:36:00 2023 +0800
rtc: change localtime to gmtime.
Signed-off-by: yangguangcai <[email protected]>
---
testing/drivertest/drivertest_rtc.c | 2 +-
1 file changed, 1 insertion(+), 1 deletion(-)
diff --git a/testing/drivertest/drivertest_rtc.c
b/testing/drivertest/drivertest_rtc.c
index 27d9985b9..0dbf9cebb 100644
--- a/testing/drivertest/drivertest_rtc.c
+++ b/testing/drivertest/drivertest_rtc.c
@@ -229,7 +229,7 @@ static void add_timeout(struct rtc_time * rtc_tm, const int
delay)
timesp = timegm((struct tm *)rtc_tm);
timesp += delay;
- tm = localtime(×p);
+ tm = gmtime(×p);
rtc_tm->tm_sec = tm->tm_sec;
rtc_tm->tm_min = tm->tm_min;
rtc_tm->tm_hour = tm->tm_hour;