summaryrefslogtreecommitdiff
path: root/doc
diff options
context:
space:
mode:
authorBruno Haible <bruno@clisp.org>2023-03-22 19:39:33 +0100
committerBruno Haible <bruno@clisp.org>2023-03-22 19:39:33 +0100
commit6b8f2da25eb90ee43212a282d5617f724b19cf21 (patch)
tree416a20bb6eed405047c6776d47ad3b7da734f6a1 /doc
parentcf3252a50dc8b0c977f558cec3902d7f06857fad (diff)
downloadgnulib-6b8f2da25eb90ee43212a282d5617f724b19cf21.tar.gz
vasnwprintf: Fix test failures on FreeBSD, NetBSD, AIX, mingw.
* m4/printf.m4 (gl_SWPRINTF_WORKS): New macro. * m4/vasnprintf.m4 (gl_PREREQ_VASNWPRINTF): Invoke it and define HAVE_WORKING_SWPRINTF accordingly. * lib/vasnprintf.c: Together with HAVE_SWPRINTF, test also HAVE_WORKING_SWPRINTF. (VASNPRINTF): If WIDE_CHAR_VERSION && !DCHAR_IS_TCHAR, don't pass a wchar_t[] to snprintf. Add a workaround against mingw's snwprintf function. * doc/posix-functions/swprintf.texi: Document the null wide character bug.
Diffstat (limited to 'doc')
-rw-r--r--doc/posix-functions/swprintf.texi7
1 files changed, 7 insertions, 0 deletions
diff --git a/doc/posix-functions/swprintf.texi b/doc/posix-functions/swprintf.texi
index a87bc06c86..357cfc1ad4 100644
--- a/doc/posix-functions/swprintf.texi
+++ b/doc/posix-functions/swprintf.texi
@@ -41,6 +41,13 @@ on some platforms:
@c https://www.openwall.com/lists/musl/2023/03/20/1
musl libc 1.2.3.
@item
+This function is broken when it produces output that contains null wide
+characters on some platforms:
+@c https://www.openwall.com/lists/musl/2023/03/22/9
+musl libc 1.2.3,
+FreeBSD 13.1, NetBSD 9.0, OpenBSD 7.2, macOS 12.5, AIX 7.2,
+mingw.
+@item
This function does not support the @samp{b} directive, required by ISO C23,
on some platforms:
glibc 2.34, musl libc, macOS 12.5, FreeBSD 13.1, NetBSD 9.0, OpenBSD 7.2,