Commit 82fa3fc0 by Jerry DeLisle

re PR fortran/32235 (incorrectly position text file after backspace)

2007-06-10  Jerry DeLisle  <jvdelisle@gcc.gnu.org>

	PR libgfortran/32235
	* io/transfer.c (st_read): Remove test for end of file condition.
	(next_record_r): Add test for end of file condition.

From-SVN: r125606
parent 51c0074e
2007-06-10 Jerry DeLisle <jvdelisle@gcc.gnu.org>
PR libgfortran/32235
* io/transfer.c (st_read): Remove test for end of file condition.
(next_record_r): Add test for end of file condition.
2007-06-02 Paolo Bonzini <bonzini@gnu.org>
* configure: Regenerate.
......
......@@ -2268,6 +2268,14 @@ next_record_r (st_parameter_dt *dtp)
break;
}
if (dtp->u.p.current_unit->flags.access == ACCESS_SEQUENTIAL
&& !dtp->u.p.namelist_mode
&& dtp->u.p.current_unit->endfile == NO_ENDFILE
&& (file_length (dtp->u.p.current_unit->s) ==
file_position (dtp->u.p.current_unit->s)))
dtp->u.p.current_unit->endfile = AT_ENDFILE;
}
......@@ -2742,9 +2750,6 @@ st_read (st_parameter_dt *dtp)
switch (dtp->u.p.current_unit->endfile)
{
case NO_ENDFILE:
if (file_length (dtp->u.p.current_unit->s)
== file_position (dtp->u.p.current_unit->s))
dtp->u.p.current_unit->endfile = AT_ENDFILE;
break;
case AT_ENDFILE:
......
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment