mirror of
https://github.com/openmc-dev/openmc.git
synced 2026-07-27 05:35:49 -04:00
Fix external source indexing bug for distrib temps
This commit is contained in:
parent
f5b1a39d4a
commit
60f679d51e
1 changed files with 2 additions and 1 deletions
|
|
@ -173,7 +173,8 @@ Bank SourceDistribution::sample() const
|
|||
if (space_box->only_fissionable()) {
|
||||
// Determine material
|
||||
auto c = model::cells[cell_index - 1];
|
||||
int32_t mat_index = c->material_[instance];
|
||||
auto mat_index = c->material_.size() == 1
|
||||
? c->material_[0] : c->material_[instance];
|
||||
|
||||
if (mat_index == MATERIAL_VOID) {
|
||||
found = false;
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue