From c1062e7895a30c7546f942cd0badc2211100628d Mon Sep 17 00:00:00 2001 From: Uriel Ramirez Date: Tue, 12 Nov 2024 11:22:00 -0500 Subject: [PATCH] make fms_diag_accept_data a subroutine instead of a function --- diag_manager/diag_manager.F90 | 4 ++-- diag_manager/fms_diag_object.F90 | 5 ++--- 2 files changed, 4 insertions(+), 5 deletions(-) diff --git a/diag_manager/diag_manager.F90 b/diag_manager/diag_manager.F90 index 0714cfe59..d6078b653 100644 --- a/diag_manager/diag_manager.F90 +++ b/diag_manager/diag_manager.F90 @@ -1789,7 +1789,7 @@ LOGICAL FUNCTION diag_send_data(diag_field_id, field, time, is_in, js_in, ks_in, allocate(mask_remap(1:size(mask,1), 1:size(mask,2), 1:size(mask,3), 1)) mask_remap(:,:,:,1) = mask endif - diag_send_data = fms_diag_object%fms_diag_accept_data(diag_field_id, field_remap, mask_remap, rmask_remap, & + call fms_diag_object%fms_diag_accept_data(diag_field_id, field_remap, mask_remap, rmask_remap, & time, is_in, js_in, ks_in, ie_in, je_in, ke_in, weight, & err_msg) deallocate (field_remap) @@ -3518,7 +3518,7 @@ LOGICAL FUNCTION send_data_4d(diag_field_id, field, time, is_in, js_in, ks_in, & if (present(mask)) mask_local = mask if (present(rmask)) rmask_local = rmask - send_data_4d = fms_diag_object%fms_diag_accept_data(diag_field_id, field, mask_local, rmask_local, & + call fms_diag_object%fms_diag_accept_data(diag_field_id, field, mask_local, rmask_local, & time, is_in, js_in, ks_in, ie_in, je_in, ke_in, weight, & err_msg) diff --git a/diag_manager/fms_diag_object.F90 b/diag_manager/fms_diag_object.F90 index 1ad5b8b19..7f8ad6d9a 100644 --- a/diag_manager/fms_diag_object.F90 +++ b/diag_manager/fms_diag_object.F90 @@ -537,7 +537,7 @@ end function fms_diag_axis_init !! multithreaded case. !! \note If some of the diag manager is offloaded in the future, then it should be treated similarly !! to the multi-threaded option for processing later -logical function fms_diag_accept_data (this, diag_field_id, field_data, mask, rmask, & +subroutine fms_diag_accept_data (this, diag_field_id, field_data, mask, rmask, & time, is_in, js_in, ks_in, & ie_in, je_in, ke_in, weight, err_msg) class(fmsDiagObject_type),TARGET, INTENT(inout) :: this !< Diaj_obj to fill @@ -710,9 +710,8 @@ logical function fms_diag_accept_data (this, diag_field_id, field_data, mask, rm call this%FMS_diag_fields(diag_field_id)%set_mask(oor_mask, field_info) end if main_if !> Return false if nothing is done - fms_diag_accept_data = .TRUE. #endif -end function fms_diag_accept_data +end subroutine fms_diag_accept_data !< @brief Do the math for all the buffers subroutine do_buffer_math(this)