From fc684e873dd07cb540773c24c5934aeea7eadd70 Mon Sep 17 00:00:00 2001 From: David Wells Date: Mon, 7 Jul 2025 09:32:21 -0400 Subject: [PATCH] Fix step-30. We assume these arrays are filled with zeros - without the explicit initialization (via = {}) they instead contain arbitrary values (i.e., undefined behavior). --- examples/step-30/step-30.cc | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/examples/step-30/step-30.cc b/examples/step-30/step-30.cc index 39f6b08f4b..d394f843f1 100644 --- a/examples/step-30/step-30.cc +++ b/examples/step-30/step-30.cc @@ -711,8 +711,8 @@ namespace Step30 // We only need to consider cells which are flagged for refinement. if (cell->refine_flag_set()) { - std::array jump_in_coordinate_direction; - std::array face_area_in_coordinate_direction; + std::array jump_in_coordinate_direction = {}; + std::array face_area_in_coordinate_direction = {}; for (const auto face_no : cell->face_indices()) { -- 2.39.5