/* Copyright (c) 1979 Regents of the University of California */
static char sccsid
[] = "@(#)READE.c 1.5 %G%";
register struct iorec
*curfile
;
if (curfile
->funit
& FWRITE
) {
ERROR("%s: Attempt to read, but open for writing\n",
retval
= fscanf(curfile
->fbuf
,
"%*[ \t\n]%74[abcdefghijklmnopqrstuvwxyzABCDEFGHIJKLMNOPQRSTUVWXYZ0123456789]",
ERROR("%s: Tried to read past end of file\n", curfile
->pfname
);
for (len
= 0; len
< NAMSIZ
&& namebuf
[len
]; len
++)
cp
= name
+ sizeof (short) + *sptr
;
nextlen
= *sptr
- nextlen
;
if (nextlen
== len
&& RELEQ(len
, namebuf
, cp
)) {
return *((short *) name
) - cnt
;
ERROR("Unknown name \"%s\" found on enumerated type read\n", namebuf
);