[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]
Re: [PATCH 6/7] nstrftime, time_rz: don’t depend on tzname
From: |
Bruno Haible |
Subject: |
Re: [PATCH 6/7] nstrftime, time_rz: don’t depend on tzname |
Date: |
Tue, 18 Jun 2024 02:47:12 +0200 |
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 <bruno@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);
- Re: new module 'tzname', tm_zone and tm_gmtoff, (continued)
- [PATCH 2/7] time_r-tests: avoid tzname test, Paul Eggert, 2024/06/16
- [PATCH 1/7] nstrftime: rename HAVE_TM_GMTOFF, Paul Eggert, 2024/06/16
- [PATCH 5/7] parse-datetime: don’t depend on tzname, Paul Eggert, 2024/06/16
- [PATCH 4/7] time_r: refactor tm_zone tests, Paul Eggert, 2024/06/16
- [PATCH 6/7] nstrftime, time_rz: don’t depend on tzname, Paul Eggert, 2024/06/16
- Re: [PATCH 6/7] nstrftime, time_rz: don’t depend on tzname, Bruno Haible, 2024/06/17
- Re: [PATCH 6/7] nstrftime, time_rz: don’t depend on tzname, Paul Eggert, 2024/06/17
- Re: [PATCH 6/7] nstrftime, time_rz: don’t depend on tzname,
Bruno Haible <=
- Re: [PATCH 6/7] nstrftime, time_rz: don’t depend on tzname, Bruno Haible, 2024/06/17
- Re: [PATCH 6/7] nstrftime, time_rz: don’t depend on tzname, Bruno Haible, 2024/06/17
- Re: [PATCH 6/7] nstrftime, time_rz: don’t depend on tzname, Paul Eggert, 2024/06/17
- Re: [PATCH 6/7] nstrftime, -0000, Bruno Haible, 2024/06/18
- Re: [PATCH 6/7] nstrftime, -0000, Paul Eggert, 2024/06/18
- Re: [PATCH 6/7] nstrftime, time_rz: don’t depend on tzname, Bruno Haible, 2024/06/18
- Re: [PATCH 6/7] nstrftime, time_rz: don’t depend on tzname, Paul Eggert, 2024/06/18
- [PATCH 3/7] time: document struct tm portability, Paul Eggert, 2024/06/16
- [PATCH 7/7] nstrftime: omit never-used code, Paul Eggert, 2024/06/16
- Re: new module 'tzname', tm_zone and tm_gmtoff, Paul Eggert, 2024/06/16