+2024-10-04 Paul Eggert <eggert@cs.ucla.edu>
+
+ timegm: desync from glibc for now
+ * config/srclist.txt: Omit time/timegm.c and time/mktime-internal.h
+ for now, until we can sync glibc from Gnulib.
+ * lib/mktime-internal.h, lib/timegm.c: Revert autoupdate, going
+ back to the recent Gnulib-specific version.
+
2024-10-03 Paul Eggert <eggert@cs.ucla.edu>
mktime: prefer static_assert to verify
$LIBCSRC stdlib/tst-stdc_trailing_ones.c tests/from-glibc
$LIBCSRC stdlib/tst-stdc_trailing_zeros.c tests/from-glibc
#$LIBCSRC sysdeps/generic/eloop-threshold.h lib
-$LIBCSRC time/timegm.c lib
+#$LIBCSRC time/timegm.c lib
#$LIBCSRC time/mktime.c lib
-$LIBCSRC time/mktime-internal.h lib
+#$LIBCSRC time/mktime-internal.h lib
# \f
# All below here commented out in forlorn hope of future syncs.
#endif
/* Subroutine of mktime. Return the time_t representation of TP and
- normalize TP, given that a struct tm * maps to a time_t as performed
- by FUNC. Record next guess for localtime-gmtime offset in *OFFSET. */
-extern __time64_t __mktime_internal (struct tm *tp,
- struct tm *(*func) (__time64_t const *,
- struct tm *),
+ normalize TP, given that a struct tm * maps to a time_t. If
+ LOCAL, the mapping is performed by localtime_r, otherwise by gmtime_r.
+ Record next guess for localtime-gmtime offset in *OFFSET. */
+extern __time64_t __mktime_internal (struct tm *tp, bool local,
mktime_offset_t *offset) attribute_hidden;
{
static mktime_offset_t gmtime_offset;
tmp->tm_isdst = 0;
- return __mktime_internal (tmp, __gmtime64_r, &gmtime_offset);
+ return __mktime_internal (tmp, false, &gmtime_offset);
}
#if defined _LIBC && __TIMESIZE != 64