This is the mail archive of the gcc-bugs@gcc.gnu.org mailing list for the GCC project.


Index Nav: [Date Index] [Subject Index] [Author Index] [Thread Index]
Message Nav: [Date Prev] [Date Next] [Thread Prev] [Thread Next]
Other format: [Raw text]

[Bug fortran/31366] Last record truncated for read after short write, direct access file



------- Comment #6 from jvdelisle at gcc dot gnu dot org  2007-03-31 06:06 -------
Here is a preliminary patch for this. 

Index: io/transfer.c
===================================================================
*** io/transfer.c       (revision 123355)
--- io/transfer.c       (working copy)
*************** read_block_direct (st_parameter_dt *dtp,
*** 411,417 ****
          /* Short read, e.g. if we hit EOF.  Apparently, we read
           more than was written to the last record.  */
          *nbytes = to_read_record;
-         generate_error (&dtp->common, ERROR_SHORT_RECORD, NULL);
          return;
        }

--- 411,416 ----


-- 


http://gcc.gnu.org/bugzilla/show_bug.cgi?id=31366


Index Nav: [Date Index] [Subject Index] [Author Index] [Thread Index]
Message Nav: [Date Prev] [Date Next] [Thread Prev] [Thread Next]