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/33108] New: unformatted string write errors with End of record.


program writebug
       character*40 string1
       character*40 string2
       write(string1,*)string2
       end

compiled with no options with gfortran this results in:

At line 4 of file test.f
Fortran runtime error: End of record

Either increasing the size of string1 to 41 or using a formatted write fixes
the problem.  This smells like null termination issue maybe?  Fortran isn't
supposed to leave space for null characters though.  Anyway, this same code
works fine with f77 in gcc 3.4.4.


-- 
           Summary: unformatted string write errors with End of record.
           Product: gcc
           Version: 4.1.2
            Status: UNCONFIRMED
          Severity: normal
          Priority: P3
         Component: fortran
        AssignedTo: unassigned at gcc dot gnu dot org
        ReportedBy: dagurasu15 at hotmail dot com
  GCC host triplet: P4


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


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