From 118816de3383ff12769349784689141355cc787c Mon Sep 17 00:00:00 2001 From: Florian Weimer Date: Mon, 19 Dec 2022 18:56:55 +0100 Subject: 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 --- include/printf_buffer.h | 1 + 1 file changed, 1 insertion(+) (limited to 'include') diff --git a/include/printf_buffer.h b/include/printf_buffer.h index 168555d8d3..e7a45fb45f 100644 --- a/include/printf_buffer.h +++ b/include/printf_buffer.h @@ -196,6 +196,7 @@ bool __printf_buffer_flush (struct __printf_buffer *buf) attribute_hidden; enum __wprintf_buffer_mode { __wprintf_buffer_mode_failed, + __wprintf_buffer_mode_swprintf, __wprintf_buffer_mode_to_file, }; -- cgit v1.2.3