diff options
-rw-r--r-- | ChangeLog | 6 | ||||
-rw-r--r-- | lib.c | 5 |
2 files changed, 11 insertions, 0 deletions
@@ -1,3 +1,9 @@ +2014-03-29 Kaz Kylheku <kaz@kylheku.com> + + * lib.c (string_time): If possible, change the timezone in the + struct tm from "GMT" to "UTC", so that the time_string_utc + function will use UTC for the %Z format. + 2014-03-27 Kaz Kylheku <kaz@kylheku.com> Fix a bug arising from putting generation 1 objects into the @@ -5666,6 +5666,11 @@ static val string_time(struct tm *(*break_time_fn)(const time_t *, struct tm *), if (break_time_fn(&time, &broken_out_time) == 0) return nil; +#if HAVE_TM_ZONE + if (strcmp(broken_out_time.TM_ZONE, "GMT") == 0) + broken_out_time.TM_ZONE = "UTC"; +#endif + if (strftime(buffer, sizeof buffer, format, &broken_out_time) == 0) buffer[0] = 0; |