From: Thomas Henlich <Thomas.H<enlich@im...> - 2002-08-22 13:50:25
I noticed a problem in the Gnu Fortran compiler (MINGW). It does not
appear on Linux, so it seems to be MINGW-specific.
The following program:
un = 11
open (un, file='test.txt')
read (un, *)
write (un, '(A)') '2222'
when run on a file test.txt with the following 2 lines:
does not (as expected) write to line 2 of the file. Instead nothing
happens to this file.
After inserting a "call fseek(un, 0, 1)" before the write command it
suddenly works! However since I need to write portable Fortran code this
is not really an option.
Can anybody help me here?
Thomas Henlich c/o Technische Universitaet Dresden
Institut fuer Maschinenelemente und Maschinenkonstruktion
D-01062 Dresden, Germany; Tel/Fax: +49(0)351 463 34232/37137