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/26464] New: Runtime I/O error/invald argument on READ


With the following test case: Either an invalid argument or abort triggered on
READ depending on datasize.  Initial test case from Dale Ranta Comment #15 of
pr26423.  Seems to trigger for datasize less then 1022.

      program test
      integer,parameter :: datasize = 1020
      dimension idata(datasize)
        idata(1)   =  -1
        idata(  datasize)   =  -2
       write(11)idata
        idata(1)   =  -2
        idata(  datasize)   =  -3
       write(11)idata
        idata(1)   =  -3
        idata(  datasize)   =  -4
       write(11)idata
        idata(1)   =  -4
        idata(  datasize)   =  -5
       write(11)idata
       read(11,end=        1000 )idata
       call abort()
 1000  continue
       backspace 11
       backspace 11
       backspace 11
       read(11,end=        1001 )idata
        if(idata(1).ne.  -3.or.idata(  datasize).ne.  -4)then
            write(6,*)idata(1),idata(  datasize)
            call abort()
        endif
        stop
 1001  continue
       print *, "Read Error."
 1010  stop
      end


-- 
           Summary: Runtime I/O error/invald argument on READ
           Product: gcc
           Version: 4.2.0
            Status: UNCONFIRMED
          Severity: normal
          Priority: P3
         Component: libfortran
        AssignedTo: unassigned at gcc dot gnu dot org
        ReportedBy: jvdelisle at gcc dot gnu dot org
  GCC host triplet: i686-pc-linux-gnu


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


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