diff --git a/src/global.F90 b/src/global.F90 index e282724b03..3c5e411fac 100644 --- a/src/global.F90 +++ b/src/global.F90 @@ -215,29 +215,39 @@ module global contains !=============================================================================== -! FREE_MEMORY deallocates all allocatable arrays in the program, namely the -! cells, surfaces, materials, and sources +! FREE_MEMORY deallocates all global allocatable arrays in the program !=============================================================================== subroutine free_memory() ! Deallocate cells, surfaces, materials if (allocated(cells)) deallocate(cells) + if (allocated(universes)) deallocate(universes) + if (allocated(lattices)) deallocate(lattices) if (allocated(surfaces)) deallocate(surfaces) if (allocated(materials)) deallocate(materials) - if (allocated(lattices)) deallocate(lattices) - ! Deallocate cross section data and listings + ! Deallocate cross section data, listings, and cache if (allocated(nuclides)) deallocate(nuclides) if (allocated(sab_tables)) deallocate(sab_tables) if (allocated(xs_listings)) deallocate(xs_listings) + if (allocated(micro_xs)) deallocate(micro_xs) + + ! Deallocate tally-related arrays + if (allocated(meshes)) deallocate(meshes) + if (allocated(tallies)) deallocate(tallies) + if (allocated(analog_tallies)) deallocate(analog_tallies) + if (allocated(tracklength_tallies)) deallocate(tracklength_tallies) + if (allocated(current_tallies)) deallocate(current_tallies) + if (allocated(tally_maps)) deallocate(tally_maps) ! Deallocate energy grid if (allocated(e_grid)) deallocate(e_grid) - ! Deallocate fission and source bank + ! Deallocate fission and source bank and entropy if (allocated(fission_bank)) deallocate(fission_bank) if (allocated(source_bank)) deallocate(source_bank) + if (allocated(entropy_p)) deallocate(entropy_p) end subroutine free_memory diff --git a/src/intercycle.F90 b/src/intercycle.F90 index 3ee37a05d2..05f58313ff 100644 --- a/src/intercycle.F90 +++ b/src/intercycle.F90 @@ -78,7 +78,7 @@ contains ! runs enough particles to avoid this in the first place. if (n_bank == 0) then - message = "No fission sites banked on procesor " // to_str(rank) + message = "No fission sites banked on processor " // to_str(rank) call fatal_error() end if