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 libfortran/25139] [4.1/4.2 regression] "Invalid argument" error on I/O



------- Comment #14 from dir at lanl dot gov  2005-12-21 19:36 -------
After tracing the errors for a while, it became clean that "active" pointer
into the read/write buffer was not being correctly updated. Adding one line (
s->active=0; ) to the bottom of routine "fd_truncate" in file "unix.c" fixes
these errors. All the examples here run OK with this patch and I built 16 of my
programs and ran their many test problems with no errors. I tried to run the
fortran testsuite with "make check-gfortran", but check-gfortran is not in the
makefile. It would be nice if just fortran testsuite could be run.



*** unix.c      Wed Dec 21 08:11:12 2005
--- unixoriginal.c      Wed Dec 21 08:10:27 2005
***************
*** 601,608 ****
      }

    s->physical_offset = s->file_length = s->logical_offset;
-   
-   s->active=0;

    return SUCCESS;
  }
--- 601,606 ----


-- 


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


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