diff --git a/mediator/esmFlds.F90 b/mediator/esmFlds.F90 index 777b05624..0a7dfbd9a 100644 --- a/mediator/esmFlds.F90 +++ b/mediator/esmFlds.F90 @@ -775,7 +775,7 @@ subroutine med_fldList_Document_Mapping(logunit, med_coupling_active) ! ocn-> atm mappings for atm/ocn fluxes computed in mediator on the ocn grid nsrc = compocn ndst = compatm - if (med_coupling_active(nsrc,ndst)) then + if (med_coupling_active(nsrc,ndst) .and. associated(fldListMed_aoflux%flds)) then do n = 1,size(fldListMed_aoflux%flds) mapindex = fldlistMed_aoflux%flds(n)%mapindex(ndst) if ( mapindex /= mapunset) then