* lib/is_l-impl.h (FUNC): Fix array index on old NetBSD and OpenBSD.
* lib/to_l-impl.h (FUNC): Likewise.
* lib/strcasecmp_l.c (strcasecmp_l): Likewise.
* lib/strncasecmp_l.c (strncasecmp_l): Likewise.
* lib/strerror_l.c (strerror_l_r): Likewise.
+2025-02-20 Bruno Haible <bruno@clisp.org>
+
+ *_l: Fix mistake.
+ * lib/is_l-impl.h (FUNC): Fix array index on old NetBSD and OpenBSD.
+ * lib/to_l-impl.h (FUNC): Likewise.
+ * lib/strcasecmp_l.c (strcasecmp_l): Likewise.
+ * lib/strncasecmp_l.c (strncasecmp_l): Likewise.
+ * lib/strerror_l.c (strerror_l_r): Likewise.
+
2025-02-19 Bruno Haible <bruno@clisp.org>
readutmp: Let callers distinguish LOGINs from USERs.
FUNC (int c, locale_t locale)
{
struct gl_locale_category_t *plc =
- &locale->category[gl_log2_lc_mask (LC_CTYPE)];
+ &locale->category[gl_log2_lcmask_to_index (gl_log2_lc_mask (LC_CTYPE))];
if (plc->is_c_locale)
/* Implementation for the "C" locale. */
return C_FUNC (c);
#if GNULIB_defined_locale_t
struct gl_locale_category_t *plc =
- &locale->category[gl_log2_lc_mask (LC_CTYPE)];
+ &locale->category[gl_log2_lcmask_to_index (gl_log2_lc_mask (LC_CTYPE))];
if (plc->is_c_locale)
/* Implementation for the "C" locale. */
return c_strcasecmp (s1, s2);
#if GNULIB_defined_locale_t
struct gl_locale_category_t *plc =
- &locale->category[gl_log2_lc_mask (LC_MESSAGES)];
+ &locale->category[gl_log2_lcmask_to_index (gl_log2_lc_mask (LC_MESSAGES))];
if (plc->is_c_locale)
{
/* Implementation for the "C" locale. */
#if GNULIB_defined_locale_t
struct gl_locale_category_t *plc =
- &locale->category[gl_log2_lc_mask (LC_CTYPE)];
+ &locale->category[gl_log2_lcmask_to_index (gl_log2_lc_mask (LC_CTYPE))];
if (plc->is_c_locale)
/* Implementation for the "C" locale. */
return c_strncasecmp (s1, s2, n);
FUNC (int c, locale_t locale)
{
struct gl_locale_category_t *plc =
- &locale->category[gl_log2_lc_mask (LC_CTYPE)];
+ &locale->category[gl_log2_lcmask_to_index (gl_log2_lc_mask (LC_CTYPE))];
if (plc->is_c_locale)
/* Implementation for the "C" locale. */
return C_FUNC (c);