8 const char test_name[128] = "child-syn-read";
10 static char buf[BUF_SIZE];
13 main (int argc, const char *argv[])
21 check (argc == 2, "argc must be 2, actually %d", argc);
22 child_idx = atoi (argv[1]);
25 random_bytes (buf, sizeof buf);
27 check ((fd = open (filename)) > 1, "open \"%s\"", filename);
28 for (i = 0; i < sizeof buf; i++)
31 check (read (fd, &c, 1) > 0, "read \"%s\"", filename);
32 compare_bytes (&c, buf + i, 1, i, filename);