Commit f53d3f93 by Bud Davis Committed by Bud Davis

re PR libfortran/18778 (ENDFILE is not functionnal)

2005-01-16  Bud Davis  <bdavis9659@comcast.net>

        PR fortran/18778
        * gfortran.dg/endfile_2.f90: New test.

        * io/transfer.c (us_read): no bytes available is not a
        runtime error.

From-SVN: r93737
parent 412dc870
2005-01-16 Bud Davis <bdavis9659@comcast.net>
PR fortran/18778
* gfortran.dg/endfile_2.f90: New test.
2005-01-16 Steven G. Kargl <kargls@comcast.net>
PR 19168
......
! { dg-do run }
! pr18778 abort on endfile without opening unit
program test
implicit none
integer i
endfile(8)
rewind(8)
read(8,end=0023)i
call abort ! should never get here
stop
0023 continue
end
2004-01-16 Bud Davis <bdavis9659@comcast.net>
PR fortran/18778
* io/transfer.c (us_read): no bytes available is not a
runtime error.
2005-01-15 Bud Davis <bdavis9659@comcast.net>
PR fortran/18983
......
......@@ -843,6 +843,9 @@ us_read (void)
n = sizeof (gfc_offset);
p = salloc_r (current_unit->s, &n);
if (n == 0)
return; /* end of file */
if (p == NULL || n != sizeof (gfc_offset))
{
generate_error (ERROR_BAD_US, NULL);
......
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