casaroli commented on code in PR #21733:
URL: https://github.com/apache/nuttx/pull/21733#discussion_r4546637924


##########
libs/libc/time/lib_localtime.c:
##########
@@ -525,32 +530,51 @@ static void scrub_abbrs(struct state_s *sp)
     }
 }
 
+static void update_tzname(FAR struct state_s *sp,
+                          FAR const struct ttinfo_s *ttisp)
+{
+  tzname[ttisp->tt_isdst] = &sp->chars[ttisp->tt_desigidx];
+  if (ttisp->tt_isdst)
+    {
+      daylight = 1;
+    }
+  else
+    {
+      timezone = -ttisp->tt_utoff;
+    }
+}
+
 static void settzname(void)
 {
   FAR struct state_s * const sp = g_lcl_ptr;
   int i;
 
   tzname[0] = tzname[1] = (FAR char *)g_wildabbr;
+  daylight = 0;

Review Comment:
   Done.



-- 
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.

To unsubscribe, e-mail: [email protected]

For queries about this service, please contact Infrastructure at:
[email protected]

Reply via email to