1
0
mirror of https://git.savannah.gnu.org/git/gnulib.git synced 2025-08-08 17:22:05 +03:00

string-buffer: Remove INT_MAX limitation.

* lib/string-buffer.h (sb_appendvf, sb_appendf): Document that errno is
set upon failure.
* lib/string-buffer-printf.c: Include <errno.h>.
(sb_appendvf): Call vsnzprintf instead of vsnprintf. Ensure errno is
set upon failure.
(sb_appendf): Likewise.
* modules/string-buffer (Depends-on): Add vsnzprintf-posix. Remove
vsnprintf-posix.
* tests/test-string-buffer.c (main): Test error code from sb_appendf.
This commit is contained in:
Bruno Haible
2024-09-24 18:31:49 +02:00
parent 413cbae0c2
commit 778a55c4a8
5 changed files with 78 additions and 37 deletions

View File

@@ -10,7 +10,7 @@ Depends-on:
stdbool
attribute
stdarg
vsnprintf-posix
vsnzprintf-posix
configure.ac: