10 char *sp1
, *sp2
, *sp3
, *sp4
;
11 wchar_t *lsp1
, *lsp2
, *lsp3
, *lsp4
;
14 wchar_t wbuf
[2048+64];
20 printf ("test at line %d failed\n", __LINE__); \
23 setlocale (LC_ALL
, "de_DE.UTF-8");
24 if (sscanf ("A \xc3\x84-\t\t\xc3\x84-abcdefbcd\t\xc3\x84-B",
25 "A%ms%10ms%4m[bcd]%4mcB", &sp1
, &sp2
, &sp3
, &sp4
) != 4)
29 if (strcmp (sp1
, "\xc3\x84-") != 0)
32 if (strcmp (sp2
, "\xc3\x84-abcdefb") != 0)
35 if (strcmp (sp3
, "cd") != 0)
38 if (memcmp (sp4
, "\t\xc3\x84-", 4) != 0)
43 if (sscanf ("A \xc3\x84-\t\t\xc3\x84-abcdefbcd\t\xc3\x84-BB",
44 "A%mS%10mls%4ml[bcd]%4mCB", &lsp1
, &lsp2
, &lsp3
, &lsp4
) != 4)
48 if (wcscmp (lsp1
, L
"\xc4-") != 0)
51 if (wcscmp (lsp2
, L
"\xc4-abcdefbc") != 0)
54 if (wcscmp (lsp3
, L
"d") != 0)
57 if (memcmp (lsp4
, L
"\t\xc4-B", 4 * sizeof (wchar_t)) != 0)
62 memset (buf
, '/', sizeof (buf
));
71 if (sscanf (buf
, "%ms%mc", &sp1
, &sp2
) != 2)
75 if (sp1
[0] != '\xc3' || sp1
[1] != '\x84'
76 || sp1
[2046] != '\xc3' || sp1
[2047] != '\x84'
81 for (i
= 2; i
< 2056; i
++)
89 if (sscanf (buf
, "%2048ms%mc", &sp3
, &sp4
) != 2)
93 if (sp3
[0] != '\xc3' || sp3
[1] != '\x84'
94 || sp3
[2046] != '\xc3' || sp3
[2047] != '\x84'
97 for (i
= 2; i
< 2046; i
++)
105 if (sscanf (buf
, "%4mc%1500m[dr/]%548m[abc/d]%3mc", &sp1
, &sp2
, &sp3
, &sp4
)
110 if (memcmp (sp1
, "\t \xc3\x84", 4) != 0)
113 for (i
= 0; i
< 1500; i
++)
116 if (sp2
[1500] != '\0')
119 for (i
= 0; i
< 544; i
++)
122 if (sp3
[544] != '\0')
125 if (memcmp (sp4
, "\xc3\x84/", 3) != 0)
129 if (sscanf (buf
, "%mS%mC", &lsp1
, &lsp2
) != 2)
133 if (lsp1
[0] != L
'\xc4' || lsp1
[2045] != L
'\xc4'
134 || lsp1
[2054] != L
'\0')
137 for (i
= 1; i
< 2054; i
++)
141 if (lsp2
[0] != L
'\t')
145 if (sscanf (buf
, "%2048mls%mlc", &lsp3
, &lsp4
) != 2)
149 if (lsp3
[0] != L
'\xc4' || lsp3
[2045] != L
'\xc4'
150 || lsp3
[2048] != L
'\0')
153 for (i
= 1; i
< 2048; i
++)
161 if (sscanf (buf
, "%4mC%1500ml[dr/]%548ml[abc/d]%3mlc",
162 &lsp1
, &lsp2
, &lsp3
, &lsp4
) != 4)
166 if (memcmp (lsp1
, L
"\t \xc4/", 4 * sizeof (wchar_t)) != 0)
169 for (i
= 0; i
< 1500; i
++)
172 if (lsp2
[1500] != L
'\0')
175 for (i
= 0; i
< 543; i
++)
178 if (lsp3
[543] != L
'\0')
181 if (memcmp (lsp4
, L
"\xc4//", 3 * sizeof (wchar_t)) != 0)