This is the mail archive of the
gcc-bugs@gcc.gnu.org
mailing list for the GCC project.
[Bug libfortran/25835] Segfault or Bad Address error on unformatted sequential READ
- From: "jvdelisle at gcc dot gnu dot org" <gcc-bugzilla at gcc dot gnu dot org>
- To: gcc-bugs at gcc dot gnu dot org
- Date: 24 Jan 2006 05:05:38 -0000
- Subject: [Bug libfortran/25835] Segfault or Bad Address error on unformatted sequential READ
- References: <bug-25835-10743@http.gcc.gnu.org/bugzilla/>
- Reply-to: gcc-bugzilla at gcc dot gnu dot org
------- Comment #6 from jvdelisle at gcc dot gnu dot org 2006-01-24 05:05 -------
I have confirmed Dale's discovery here which gave me the hint I needed. The
following patch fixes all the cases presented in comments above, passes
regression testing and passes NIST testing. No need for patch in unix.c.
Index: io/transfer.c
===================================================================
*** io/transfer.c (revision 109870)
--- io/transfer.c (working copy)
*************** export_proto(st_read_done);
*** 2173,2178 ****
--- 2173,2179 ----
void
st_read_done (st_parameter_dt *dtp)
{
+ flush(dtp->u.p.current_unit->s);
finalize_transfer (dtp);
free_format_data (dtp);
free_ionml (dtp);
Dale, please give this a spin if you can. And thanks doubly for your help!
--
http://gcc.gnu.org/bugzilla/show_bug.cgi?id=25835