From ef7691e49aef9f6916711f42755909bdad7c50d1 Mon Sep 17 00:00:00 2001 From: David Minton Date: Fri, 21 May 2021 13:38:31 -0400 Subject: [PATCH] Fixed a two-part boolean statement on a possibly deallocated array that was not allowed by the new version of gfortran (10.2) --- src/util/util_solve_linear_system.f90 | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/src/util/util_solve_linear_system.f90 b/src/util/util_solve_linear_system.f90 index a9981fc87..59a72b119 100644 --- a/src/util/util_solve_linear_system.f90 +++ b/src/util/util_solve_linear_system.f90 @@ -89,7 +89,7 @@ function solve_wbs(u) result(x) ! solve with backward substitution integer(I4B) :: i,n n = size(u, 1) - if (allocated(x) .and. (size(x) /= n)) deallocate(x) + if (allocated(x)) deallocate(x) if (.not.allocated(x)) allocate(x(n)) call ieee_set_halting_mode(ieee_divide_by_zero, .false.) do i = n, 1, -1