]> git.ipfire.org Git - thirdparty/gettext.git/commitdiff
intl: Merge from glibc.
authorBruno Haible <bruno@clisp.org>
Sat, 30 Sep 2023 18:38:29 +0000 (20:38 +0200)
committerBruno Haible <bruno@clisp.org>
Sat, 30 Sep 2023 22:36:55 +0000 (00:36 +0200)
Apply commit
2019-09-05  Florian Weimer  <fweimer@redhat.com>
locale: Avoid zero-length array in _nl_category_names [BZ #24962]

gettext-runtime/intl/dcigettext.c

index a90b509bd925ef3eb4317d8589a25626f7493ba5..8e7db219f660db1fe2a5e174157042f43d0d4d40 100644 (file)
@@ -329,8 +329,7 @@ static const char *guess_category_value (int category,
 
 #ifdef _LIBC
 # include "../locale/localeinfo.h"
-# define category_to_name(category) \
-  _nl_category_names.str + _nl_category_name_idxs[category]
+# define category_to_name(category) _nl_category_names_get (category)
 #else
 static const char *category_to_name (int category);
 #endif