libio: Convert __vswprintf_internal to buffers (bug 27857)
commit118816de3383ff12769349784689141355cc787c
authorFlorian Weimer <fweimer@redhat.com>
Mon, 19 Dec 2022 17:56:55 +0000 (19 18:56 +0100)
committerFlorian Weimer <fweimer@redhat.com>
Mon, 19 Dec 2022 17:56:55 +0000 (19 18:56 +0100)
treefa858eff7a21613e38e532ac9c1d0edd1651aeab
parent5365acc567a49270b4341b9d325794ec554258d9
libio: Convert __vswprintf_internal to buffers (bug 27857)

Always null-terminate the buffer and set E2BIG if the buffer is too
small.  This fixes bug 27857.

Reviewed-by: Adhemerval Zanella <adhemerval.zanella@linaro.org>
elf/Makefile
include/printf_buffer.h
libio/tst_swprintf.c
libio/vswprintf.c
manual/stdio.texi
stdio-common/wprintf_buffer_flush.c