Skip to content

Commit

Permalink
Avoids posting Kv_slow when it is not initialized
Browse files Browse the repository at this point in the history
  • Loading branch information
gustavo-marques committed Sep 17, 2019
1 parent ba2f186 commit 992e826
Showing 1 changed file with 2 additions and 1 deletion.
3 changes: 2 additions & 1 deletion src/parameterizations/vertical/MOM_vert_friction.F90
Original file line number Diff line number Diff line change
Expand Up @@ -1015,7 +1015,8 @@ subroutine vertvisc_coef(u, v, h, forces, visc, dt, G, GV, US, CS, OBC)
endif

! Offer diagnostic fields for averaging.
if (CS%id_Kv_slow > 0) call post_data(CS%id_Kv_slow, visc%Kv_slow, CS%diag)
if (associated(visc%Kv_slow) .and. (CS%id_Kv_slow > 0)) &
call post_data(CS%id_Kv_slow, visc%Kv_slow, CS%diag)
if (CS%id_Kv_u > 0) call post_data(CS%id_Kv_u, Kv_u, CS%diag)
if (CS%id_Kv_v > 0) call post_data(CS%id_Kv_v, Kv_v, CS%diag)
if (CS%id_au_vv > 0) call post_data(CS%id_au_vv, CS%a_u, CS%diag)
Expand Down

0 comments on commit 992e826

Please sign in to comment.