openf95 problem with record lengths

Discussion created by milos on Aug 28, 2011
Latest reply on Jan 7, 2012 by milos
openf95 problem with record lengths


I am trying to compile a Fortran 90 code that has previously run successfully using the Intel compiler (and many others, like Compaq, Cray, etc.)

I get an error like the below, when the code tries to write formatted output to a file, and the complaint is about record length:


lib-4211 : UNRECOVERABLE library error 

  A WRITE operation tried to write a record that was too long.

Encountered during a sequential formatted WRITE to unit 30

Fortran unit 30 is connected to a sequential formatted text file: "diel01"

 Current format:   100 FORMAT(9999e15.6)

I have verified by hand testing that this happens because the "record length" is by default not large enough.  I opened the file with:
   OPEN(unit=30,file='diel'//ext,status = 'unknown')
If I change this to include a larger record length like this:
   OPEN(unit=30,file='diel'//ext,status = 'unknown',recl=1500000)
My questions:
1) Why is this happening?  No other compiler needs the recl, so the default values must be different..
2) I don't want to go through my whole code and change insert the recl specification into every open statement.  Does the openf95 compiler have a flag that can set the default record length or something like that?
3) Is there another clean way to solve this?
4) Is this openf95 not following Fortran standards, other compilers not doing so, or neither?
Thanks very much for any help in advance!