]>
git.wh0rd.org - ICEs.git/blob - 182288/test.c
8 char buf
[1]; /* Change 256 to 1, and you can see the wierd behaviour
9 * of fgets if run against glibc-2.3.5 */
12 system("touch null_file");
14 /* Create this file before starting! */
15 f
= fopen("null_file", "r");
23 if (!fgets(buf
, sizeof buf
, f
)) {
30 puts("Wierd behaviour");
34 if (strchr(buf
, '\n')) {
35 printf("Read %u lines.\n", ++lines
);