Skip to content

Commit

Permalink
fortran: set writeunit before opening file
Browse files Browse the repository at this point in the history
  • Loading branch information
adammoody committed Apr 15, 2019
1 parent 2858231 commit 691610e
Showing 1 changed file with 1 addition and 0 deletions.
1 change: 1 addition & 0 deletions examples/src/writeread.f90
Original file line number Diff line number Diff line change
Expand Up @@ -41,6 +41,7 @@ program write_read_F
forall(i=1:ni,j=1:nj,k=1:nk) &
W1(i,j,k) = nodeoff*mynod+i+ni*(j-1+nj*(k-1))

writeunit = mynod
open(unit=writeunit,file=fname,form='unformatted',action='write')

write(writeunit,iostat=ios) W1
Expand Down

0 comments on commit 691610e

Please sign in to comment.