Skip to content

Commit

Permalink
Merge pull request #492 from FESOM/raw_restart_minor_fix
Browse files Browse the repository at this point in the history
remove unnecessary / in raw restarts esultPath…
  • Loading branch information
JanStreffing committed Mar 12, 2024
2 parents 49a74cf + 7dc9c8a commit 8f7aa22
Showing 1 changed file with 6 additions and 6 deletions.
12 changes: 6 additions & 6 deletions src/io_restart.F90
Original file line number Diff line number Diff line change
Expand Up @@ -194,12 +194,12 @@ subroutine restart(istep, nstart, ntotal, l_read, which_readr, ice, dynamics, tr
! initialize directory for core dump restart
if(.not. initialized_raw) then
initialized_raw = .true.
raw_restart_dirpath = trim(ResultPath)//"/fesom_raw_restart/np"//int_to_txt(partit%npes)
raw_restart_infopath = trim(ResultPath)//"/fesom_raw_restart/np"//int_to_txt(partit%npes)//".info"
raw_restart_dirpath = trim(ResultPath)//"fesom_raw_restart/np"//int_to_txt(partit%npes)
raw_restart_infopath = trim(ResultPath)//"fesom_raw_restart/np"//int_to_txt(partit%npes)//".info"
if(raw_restart_length_unit /= "off") then
if(partit%mype == RAW_RESTART_METADATA_RANK) then
! execute_command_line with mkdir sometimes fails, use a custom implementation around mkdir from C instead
call mkdir(trim(ResultPath)//"/fesom_raw_restart") ! we have no mkdir -p, create the intermediate dirs separately
call mkdir(trim(ResultPath)//"fesom_raw_restart") ! we have no mkdir -p, create the intermediate dirs separately
call mkdir(raw_restart_dirpath)
end if
call MPI_Barrier(partit%MPI_COMM_FESOM, mpierr) ! make sure the dir has been created before we continue...
Expand All @@ -210,12 +210,12 @@ subroutine restart(istep, nstart, ntotal, l_read, which_readr, ice, dynamics, tr
! initialize directory for derived type binary restart
if(.not. initialized_bin) then
initialized_bin = .true.
bin_restart_dirpath = trim(ResultPath)//"/fesom_bin_restart/np"//int_to_txt(partit%npes)
bin_restart_infopath = trim(ResultPath)//"/fesom_bin_restart/np"//int_to_txt(partit%npes)//".info"
bin_restart_dirpath = trim(ResultPath)//"fesom_bin_restart/np"//int_to_txt(partit%npes)
bin_restart_infopath = trim(ResultPath)//"fesom_bin_restart/np"//int_to_txt(partit%npes)//".info"
if(bin_restart_length_unit /= "off") then
if(partit%mype == RAW_RESTART_METADATA_RANK) then
! execute_command_line with mkdir sometimes fails, use a custom implementation around mkdir from C instead
call mkdir(trim(ResultPath)//"/fesom_bin_restart") ! we have no mkdir -p, create the intermediate dirs separately
call mkdir(trim(ResultPath)//"fesom_bin_restart") ! we have no mkdir -p, create the intermediate dirs separately
call mkdir(bin_restart_dirpath)
end if
call MPI_Barrier(partit%MPI_COMM_FESOM, mpierr) ! make sure the dir has been created before we continue...
Expand Down

0 comments on commit 8f7aa22

Please sign in to comment.