From 6201ced9727705818c937fa436c5ee7a4583b5d9 Mon Sep 17 00:00:00 2001 From: Benjamin Auer Date: Wed, 17 Jul 2024 11:50:49 -0400 Subject: [PATCH] fixes #2913 --- CHANGELOG.md | 2 ++ field_utils/FieldUtilities.F90 | 4 ++-- 2 files changed, 4 insertions(+), 2 deletions(-) diff --git a/CHANGELOG.md b/CHANGELOG.md index 21512b2194c4..21333b8d2371 100644 --- a/CHANGELOG.md +++ b/CHANGELOG.md @@ -13,6 +13,8 @@ and this project adheres to [Semantic Versioning](https://semver.org/spec/v2.0.0 ### Fixed +- Fixed bug in FieldSet routines when passing R8 ESMF fields + ### Removed ### Deprecated diff --git a/field_utils/FieldUtilities.F90 b/field_utils/FieldUtilities.F90 index 130d09222f8e..e4f8e2930049 100644 --- a/field_utils/FieldUtilities.F90 +++ b/field_utils/FieldUtilities.F90 @@ -64,7 +64,7 @@ subroutine FieldSet_r8(field,constant_val,rc) if (type_kind == ESMF_TYPEKIND_R4) then call assign_fptr(field,f_ptr_r4,_RC) f_ptr_r4 = constant_val - else if (type_kind == ESMF_TYPEKIND_R4) then + else if (type_kind == ESMF_TYPEKIND_R8) then call assign_fptr(field,f_ptr_r8,_RC) f_ptr_r8 = constant_val else @@ -87,7 +87,7 @@ subroutine FieldSet_r4(field,constant_val,rc) if (type_kind == ESMF_TYPEKIND_R4) then call assign_fptr(field,f_ptr_r4,_RC) f_ptr_r4 = constant_val - else if (type_kind == ESMF_TYPEKIND_R4) then + else if (type_kind == ESMF_TYPEKIND_R8) then call assign_fptr(field,f_ptr_r8,_RC) f_ptr_r8 = constant_val else