summaryrefslogtreecommitdiff
path: root/doc
diff options
context:
space:
mode:
authorBruno Haible <bruno@clisp.org>2023-03-30 23:12:50 +0200
committerBruno Haible <bruno@clisp.org>2023-03-30 23:12:50 +0200
commit63861afac8004becc3907993cd16b59a5bca5195 (patch)
tree6247e3ab6379e50c0ab1aa83e8aae1d22c0dd5b6 /doc
parent1ab07af585358746e7fcc0176ab1716db31ca902 (diff)
downloadgnulib-63861afac8004becc3907993cd16b59a5bca5195.tar.gz
mbsrtowcs: Fix behaviour in the C locale.
* m4/mbsrtowcs.m4 (gl_FUNC_MBSRTOWCS): Invoke gl_MBRTOWC_C_LOCALE. If mbrtowc is buggy in the C locale, override also mbsrtowcs. * modules/mbsrtowcs (Files): Add m4/mbrtowc.m4. * tests/test-mbsrtowcs.c (main): Add a test of the C locale, based on tests/test-mbrtowc.c. * tests/test-mbsrtowcs5.sh: New file, based on tests/test-mbrtowc5.sh. * modules/mbsrtowcs-tests (Files): Add it. (Makefile.am): Test it. * doc/posix-functions/mbsrtowcs.texi: Mention the C locale behaviour bug.
Diffstat (limited to 'doc')
-rw-r--r--doc/posix-functions/mbsrtowcs.texi4
1 files changed, 4 insertions, 0 deletions
diff --git a/doc/posix-functions/mbsrtowcs.texi b/doc/posix-functions/mbsrtowcs.texi
index f27ec0f616..28c450ddfb 100644
--- a/doc/posix-functions/mbsrtowcs.texi
+++ b/doc/posix-functions/mbsrtowcs.texi
@@ -15,6 +15,10 @@ Minix 3.1.8, HP-UX 11.00, IRIX 6.5, mingw.
This function does not work on some platforms:
HP-UX 11, Solaris 11 2010-11.
@item
+In the C or POSIX locales, this function can return @code{(size_t) -1}
+and set @code{errno} to @code{EILSEQ}:
+glibc 2.35.
+@item
This function does not work when the first argument is NULL on some platforms:
mingw.
@end itemize