From 76f03253f184049f5fc1cb79f5cac13cabe7a578 Mon Sep 17 00:00:00 2001 From: Paul Date: Wed, 13 Sep 2023 09:35:45 +0100 Subject: [PATCH] Ensure halo exchange check doesn't overwrite failure status --- examples/halo_test/exchange_test.f90 | 7 +++---- 1 file changed, 3 insertions(+), 4 deletions(-) diff --git a/examples/halo_test/exchange_test.f90 b/examples/halo_test/exchange_test.f90 index abdeb060..c29dc5ec 100644 --- a/examples/halo_test/exchange_test.f90 +++ b/examples/halo_test/exchange_test.f90 @@ -93,7 +93,8 @@ subroutine test_exchange(orientation) print *, "ERROR: Unknow orientation "//orientation//" test is broken!" stop end if - + + orientation_passing = .true. do nlevels = 1, 3 levels=(/ xhalo * nlevels, yhalo * nlevels, zhalo * nlevels /) @@ -130,14 +131,12 @@ subroutine check(starts, ends, sizes, levels, u, passing) integer, dimension(3), intent(in) :: starts, ends, sizes, levels real(mytype), dimension(:,:,:), intent(in) :: u - logical, intent(out) :: passing + logical, intent(inout) :: passing integer :: is, ie, js, je, ks, ke integer :: i, j, k integer :: io, jo, ko integer :: idx - - passing = .true. call valid_range(starts(1), ends(1), sizes(1), nx, levels(1), is, ie) call valid_range(starts(2), ends(2), sizes(2), ny, levels(2), js, je)