mirror of
https://github.com/openmc-dev/openmc.git
synced 2026-07-28 06:05:58 -04:00
Fixed segmentation fault when forgetting to specify material on cell. Closes gh-34.
This commit is contained in:
parent
a03d164394
commit
28b2eff77d
1 changed files with 7 additions and 0 deletions
|
|
@ -132,6 +132,13 @@ contains
|
|||
c % material = cell_(i) % material
|
||||
c % fill = cell_(i) % fill
|
||||
|
||||
! Check to make sure that either material or fill was specified
|
||||
if (c % material == 0 .and. c % fill == 0) then
|
||||
msg = "Neither material nor fill was specified for cell " // &
|
||||
trim(int_to_str(c % uid))
|
||||
call fatal_error(msg)
|
||||
end if
|
||||
|
||||
! Check to make sure that both material and fill haven't been
|
||||
! specified simultaneously
|
||||
if (c % material /= 0 .and. c % fill /= 0) then
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue