{
FILE *fp = NULL, *fp_in = NULL;
FILE *out_fp = NULL, *diff_fp = NULL;
{
FILE *fp = NULL, *fp_in = NULL;
FILE *out_fp = NULL, *diff_fp = NULL;
printf("(%d)", count);fflush(stdout);
if ((fd_out = open(topcmd, O_RDONLY | O_NONBLOCK)) < 0) {
printf("(%d)", count);fflush(stdout);
if ((fd_out = open(topcmd, O_RDONLY | O_NONBLOCK)) < 0) {
if ((fd_in = open(top_in_file, O_WRONLY)) < 0) {
fprintf(stderr, "error opening %s\n", top_in_file);
exit(-1);
}
if ((fd_in = open(top_in_file, O_WRONLY)) < 0) {
fprintf(stderr, "error opening %s\n", top_in_file);
exit(-1);
}
if ((flag = fcntl(fd_out, F_GETFL)) == -1) {
printf("fcntl get failed\n");
if ((flag = fcntl(fd_out, F_GETFL)) == -1) {
printf("fcntl get failed\n");
res = select(fd_out + 1, &readSet, NULL, NULL, NULL);
res = select(fd_out + 1, &readSet, NULL, NULL, NULL);