Return to msgs.c CVS log | Up to [local] / src / usr.bin / msgs |
version 1.12, 1998/06/23 23:30:19 | version 1.13, 1999/05/13 12:59:29 | ||
---|---|---|---|
|
|
||
bounds = fopen(fname, "r"); | bounds = fopen(fname, "r"); | ||
if (bounds == NULL) { | if (bounds == NULL) { | ||
perror(fname); | if (errno == ENOENT) { | ||
exit(1); | if ((bounds = fopen(fname, "w+")) == NULL) { | ||
perror(fname); | |||
exit(1); | |||
} | |||
fprintf(bounds, "1 0\n"); | |||
rewind(bounds); | |||
} | |||
else { | |||
perror(fname); | |||
exit(1); | |||
} | |||
} | } | ||
fscanf(bounds, "%d %d\n", &firstmsg, &lastmsg); | fscanf(bounds, "%d %d\n", &firstmsg, &lastmsg); |