* tests/test-string-buffer.c: Include <wchar.h>. Don't assume that
wint_t has the same size as 'int'.
2023-09-04 Bruno Haible <bruno@clisp.org>
+ string-buffer tests: Fix a gcc -Wformat warning.
+ * tests/test-string-buffer.c: Include <wchar.h>. Don't assume that
+ wint_t has the same size as 'int'.
+
crypto/* tests: Fix some gcc -Wdiscarded-qualifiers warnings.
* tests/test-gc-hmac-md5.c (main): Change type of variables with a
string literal initializer to 'const char *'.
#include "string-buffer.h"
#include <string.h>
+#include <wchar.h>
#include "macros.h"
sb_init (&buffer);
sb_append (&buffer, "<");
- sb_appendf (&buffer, "%lc", 0x76543210);
+ sb_appendf (&buffer, "%lc", (wint_t) 0x76543210);
sb_append (&buffer, "|");
sb_appendf (&buffer, invalid_format_string_1, 1);
sb_append (&buffer, "|");