From 899b6b67996489ae6e3369156ce7017e902031a1 Mon Sep 17 00:00:00 2001 From: Paul Romano Date: Thu, 8 Feb 2018 15:34:39 -0600 Subject: [PATCH] Make sure k_generation and entropy are cleared before loading state point --- src/simulation.F90 | 13 +++++++------ 1 file changed, 7 insertions(+), 6 deletions(-) diff --git a/src/simulation.F90 b/src/simulation.F90 index 0204aaf796..34c4336944 100644 --- a/src/simulation.F90 +++ b/src/simulation.F90 @@ -434,6 +434,13 @@ contains allocate(filter_matches(n_filters)) !$omp end parallel + ! Reset global variables -- this is done before loading state point (as that + ! will potentially populate k_generation and entropy) + current_batch = 0 + call k_generation % clear() + call entropy % clear() + need_depletion_rx = .false. + ! If this is a restart run, load the state point data and binary source ! file if (restart_run) then @@ -452,12 +459,6 @@ contains end if end if - ! Reset global variables - current_batch = 0 - call k_generation % clear() - call entropy % clear() - need_depletion_rx = .false. - ! Set flag indicating initialization is done simulation_initialized = .true.