Re: Associated reads on Unix/f77 binaries [message #5609 is a reply to message #5603] |
Mon, 22 January 1996 00:00  |
steinhh
Messages: 260 Registered: June 1994
|
Senior Member |
|
|
In article <franz.8.0016A52E@bikini.gsfc.nasa.gov>, franz@bikini.gsfc.nasa.gov (
Bryan A. Franz) writes:
||>
|> Has anybody managed to do associated reads on files generated by f77 under
|> Unix ?
|>
|> I have RTFM, which states that you can't do associated reads on files
|> generated from FORTRAN 77 under Unix. Apparently, f77 sticks a longword
|> containing the number of bytes before and after each logical record. IDL's
|> readu accounts for the extra bytes, but assoc does not. It seems to me that
I
|> should still be able to do the associated reads, if I just added a dummy
|> longword on either side of my datastructure, but it does not seem to work.
|>
I think this should work. f77's idea of a logical record need not be
the same as your idea of a logical record, though! If you write one
(of your) record(s) with multiple WRITE statements, I think f77
decides that there's one record for each WRITE statement. You should
really take a look at the format of the file itself to make sure.
Use e.g., od (octal dump -- use "-h" to get hex, which I prefer) too look
at it. Once you get the number (and placement) of extra longwords
correct, it should work.
Stein Vidar
|
|
|