Skip to content

Commit

Permalink
Merge pull request #160 from COSIMA/ww3_failing_restart
Browse files Browse the repository at this point in the history
Fix WW3 failing restart
  • Loading branch information
ezhilsabareesh8 authored May 7, 2024
2 parents e0007c4 + b7d7897 commit 5373389
Show file tree
Hide file tree
Showing 2 changed files with 24 additions and 1 deletion.
3 changes: 2 additions & 1 deletion WW3/CMakeLists.txt
Original file line number Diff line number Diff line change
Expand Up @@ -44,7 +44,6 @@ target_sources(OM3_ww3 PRIVATE
WW3/model/src/w3iogomd.F90
WW3/model/src/w3iogrmd.F90
WW3/model/src/w3iopomd.F90
WW3/model/src/w3iorsmd.F90
WW3/model/src/w3iosfmd.F90
WW3/model/src/w3iotrmd.F90
WW3/model/src/w3macros.h
Expand Down Expand Up @@ -94,6 +93,8 @@ target_sources(OM3_ww3 PRIVATE
${switch_files}
)

add_patched_source(OM3_ww3 WW3/model/src/w3iorsmd.F90)

## Utilities

# ww3_grid
Expand Down
22 changes: 22 additions & 0 deletions WW3/patches/w3iorsmd.F90.patch
Original file line number Diff line number Diff line change
@@ -0,0 +1,22 @@
diff --git a/w3iorsmd.F90 b/w3iorsmd.F90.new
index ffb34d47..0e32748b 100644
--- a/w3iorsmd.F90
+++ b/w3iorsmd.F90.new
@@ -893,7 +893,7 @@ CONTAINS
WRITEBUFF(:) = 0.
WRITE (NDSR,POS=RPOS,ERR=803,IOSTAT=IERR) WRITEBUFF
WRITE (NDSR,POS=RPOS,ERR=803,IOSTAT=IERR) &
- TLEV, TICE, TRHO
+ TLEV, TICE, TRHO, TIC1, TIC5
DO IPART=1,NPART
NREC = NREC + 1
RPOS = 1_8 + LRECL*(NREC-1_8)
@@ -1078,7 +1078,7 @@ CONTAINS
IF (TYPE.EQ.'FULL') THEN
RPOS = 1_8 + LRECL*(NREC-1_8)
READ (NDSR,POS=RPOS,ERR=802,IOSTAT=IERR) &
- TLEV, TICE, TRHO
+ TLEV, TICE, TRHO, TIC1, TIC5
DO IPART=1,NPART
NREC = NREC + 1
RPOS = 1_8 + LRECL*(NREC-1_8)

0 comments on commit 5373389

Please sign in to comment.