8 #include <support/xstdio.h>
11 do_test (int argc
, char *argv
[])
14 xfreopen (argc
== 1 ? "/dev/stdout" : argv
[1], "a", stderr
);
15 /* Orient the stream. */
16 fwprintf (stderr
, L
"hello world\n");
18 static const char str
[] = "hello world! ";
19 for (int i
= 0; i
< 1000; ++i
)
20 memcpy (&buf
[i
* (sizeof (str
) - 1)], str
, sizeof (str
));
23 /* We're testing a large format string here and need to generate it
24 to avoid this source file being ridiculous. So disable the warning
25 about a generated format string. */
26 DIAG_PUSH_NEEDS_COMMENT
;
27 DIAG_IGNORE_NEEDS_COMMENT (4.9, "-Wformat-security");
32 DIAG_POP_NEEDS_COMMENT
;
38 #define TEST_FUNCTION do_test (argc, argv)
39 #include "../test-skeleton.c"