summaryrefslogtreecommitdiffstats
path: root/lib/libI77/rsfe.c
diff options
context:
space:
mode:
Diffstat (limited to 'lib/libI77/rsfe.c')
-rw-r--r--lib/libI77/rsfe.c8
1 files changed, 7 insertions, 1 deletions
diff --git a/lib/libI77/rsfe.c b/lib/libI77/rsfe.c
index 5d29bee..5ff0a33 100644
--- a/lib/libI77/rsfe.c
+++ b/lib/libI77/rsfe.c
@@ -6,7 +6,11 @@
xrd_SL(Void)
{ int ch;
if(!f__curunit->uend)
- while((ch=getc(f__cf))!='\n' && ch!=EOF);
+ while((ch=getc(f__cf))!='\n')
+ if (ch == EOF) {
+ f__curunit->uend = 1;
+ break;
+ }
f__cursor=f__recpos=0;
return(1);
}
@@ -69,5 +73,7 @@ integer s_rsfe(cilist *a) /* start */
f__cplus=0;
if(f__curunit->uwrt && f__nowreading(f__curunit))
err(a->cierr,errno,"read start");
+ if(f__curunit->uend)
+ err(f__elist->ciend,(EOF),"read start");
return(0);
}
OpenPOWER on IntegriCloud