Paul Eggert wrote:
> Thanks for reporting and fixing that. For NetBSD, a better fix is to use 
> the native timezone_t, so that Gnulib doesn't need to set and later 
> restore TZ.

Interesting. So, we have at least one platform now, where nstrftime is
multithread-safe.

Only an indentation nit:


2024-06-17  Bruno Haible  <br...@clisp.org>

        nstrftime: Correct indentation.
        * lib/strftime.c (__strftime_internal): Correct indentation of
        preprocessor directives.

diff --git a/lib/strftime.c b/lib/strftime.c
index 2db6603a23..db59d65d05 100644
--- a/lib/strftime.c
+++ b/lib/strftime.c
@@ -1351,11 +1351,11 @@ __strftime_internal (STREAM_OR_CHAR_T *s, STRFTIME_ARG 
(size_t maxsize)
                 locale_t locale = c_locale ();
                 if (!locale)
                   return 0; /* errno is set here */
-# if HAVE_STRFTIME_LZ
+#  if HAVE_STRFTIME_LZ
                 len = strftime_lz (tz, ubuf, sizeof ubuf, ufmt, tp, locale);
-# else
+#  else
                 len = strftime_l (ubuf, sizeof ubuf, ufmt, tp, locale);
-# endif
+#  endif
 # else
 #  if HAVE_STRFTIME_Z
                 len = strftime_z (tz, ubuf, sizeof ubuf, ufmt, tp);




Reply via email to