]> git.ipfire.org Git - thirdparty/glibc.git/blob - stdlib/bug-fmtmsg1.c
nptl: Move pthread_attr_setinheritsched implementation into libc.
[thirdparty/glibc.git] / stdlib / bug-fmtmsg1.c
1 #include <fmtmsg.h>
2 #include <stdio.h>
3
4
5 static int
6 do_test (void)
7 {
8 /* Ugly, but fmtmsg would otherwise print to stderr which we do not
9 want. */
10 fclose (stderr);
11 stderr = stdout;
12
13 int e1;
14 e1 = fmtmsg (MM_PRINT, "label:part", MM_WARNING, "text", "action", "tag");
15
16 int e2;
17 e2 = fmtmsg (MM_PRINT, "label2:part2", 11, "text2", "action2", "tag2");
18
19 addseverity (10, "additional severity");
20
21 int e3;
22 e3 = fmtmsg (MM_PRINT, "label3:part3", 10, "text3", "action3", "tag3");
23
24 return e1 != 0 || e2 != 0 || e3 != 0;
25 }
26
27 #define TEST_FUNCTION do_test ()
28 #include "../test-skeleton.c"