gfortran patch for PR 18778 Abort on endfile on unopened unit

Paul Brook paul@codesourcery.com
Mon Dec 27 15:18:00 GMT 2004


> 2004-12-23  Bud Davis  <bdavis9659@comcast.net>
>
>  PR fortran/18778
>  * io/transfer.c (us_read): no bytes available is not a
>         runtime error.
>  * io/endfile.c (st_endfile): open the unit if needed.

> Index: gcc/libgfortran/io/endfile.c
> ===================================================================
> !        /* endfile without an open on this unit.
> !           not an error, so let's make a unit
> !        */
> !        memset (&u_flags, '\0', sizeof (u_flags));
> !        u_flags.access = ACCESS_SEQUENTIAL;
> !        u_flags.action = ACTION_READWRITE;
> !        u_flags.form = FORM_UNFORMATTED;

Why not *_UNSPECIFIED here?

Other than that, Ok.

Paul



More information about the Fortran mailing list