IO: Add ACTION and STATUS flags to OPEN statements.
Signed-off-by: Grzegorz Kowal <grzegorz@amuncode.org>
This commit is contained in:
parent
9455f9be9a
commit
68449d0ccc
@ -2420,7 +2420,8 @@ module io
|
|||||||
'compressed_size', csize)
|
'compressed_size', csize)
|
||||||
allocate(buffer(csize))
|
allocate(buffer(csize))
|
||||||
|
|
||||||
open (newunit=io, file=file_path, access='stream', action='read')
|
open (newunit=io, file=file_path, access='stream', &
|
||||||
|
status='old', action='read')
|
||||||
read (io) buffer
|
read (io) buffer
|
||||||
close (io)
|
close (io)
|
||||||
|
|
||||||
@ -2474,7 +2475,8 @@ module io
|
|||||||
end if
|
end if
|
||||||
|
|
||||||
else
|
else
|
||||||
open (newunit=io, file=file_path, access='stream', action='read')
|
open (newunit=io, file=file_path, access='stream', &
|
||||||
|
status='old', action='read')
|
||||||
read (io) array
|
read (io) array
|
||||||
close (io)
|
close (io)
|
||||||
end if
|
end if
|
||||||
@ -2611,7 +2613,8 @@ module io
|
|||||||
filename = trim(array_file) // '.bin' // file_suffix
|
filename = trim(array_file) // '.bin' // file_suffix
|
||||||
filepath = trim(data_path) // trim(filename)
|
filepath = trim(data_path) // trim(filename)
|
||||||
|
|
||||||
open (newunit=io, file=filepath, access='stream')
|
open (newunit=io, file=filepath, access='stream', &
|
||||||
|
action='write', status='replace')
|
||||||
write (io) buffer(1:cbytes)
|
write (io) buffer(1:cbytes)
|
||||||
close (io)
|
close (io)
|
||||||
|
|
||||||
@ -2646,7 +2649,8 @@ module io
|
|||||||
filename = trim(array_file) // '.bin'
|
filename = trim(array_file) // '.bin'
|
||||||
filepath = trim(data_path) // trim(filename)
|
filepath = trim(data_path) // trim(filename)
|
||||||
|
|
||||||
open (newunit=io, file=filepath, access='stream')
|
open (newunit=io, file=filepath, access='stream', &
|
||||||
|
action='write', status='replace')
|
||||||
write (io) array
|
write (io) array
|
||||||
close (io)
|
close (io)
|
||||||
|
|
||||||
@ -5191,7 +5195,7 @@ module io
|
|||||||
write (fname, "('p',i6.6,'_',i5.5,'.xdmf')") isnap, nproc
|
write (fname, "('p',i6.6,'_',i5.5,'.xdmf')") isnap, nproc
|
||||||
write (hname, "('p',i6.6,'_',i5.5,'.h5' )") isnap, nproc
|
write (hname, "('p',i6.6,'_',i5.5,'.h5' )") isnap, nproc
|
||||||
|
|
||||||
open (unit = xdmf, file = fname, status = 'replace')
|
open (unit=xdmf, file=fname, status='replace')
|
||||||
|
|
||||||
! write the header
|
! write the header
|
||||||
!
|
!
|
||||||
@ -5379,7 +5383,7 @@ module io
|
|||||||
!
|
!
|
||||||
write (fname, "('p',i6.6,'.xdmf')") isnap
|
write (fname, "('p',i6.6,'.xdmf')") isnap
|
||||||
|
|
||||||
open (unit = xdmf, file = fname, status = 'replace')
|
open (unit=xdmf, file=fname, status='replace')
|
||||||
|
|
||||||
! write the header
|
! write the header
|
||||||
!
|
!
|
||||||
|
Loading…
x
Reference in New Issue
Block a user