mirror of
https://github.com/openmc-dev/openmc.git
synced 2026-07-27 21:55:41 -04:00
Added error if cross sections path is a folder (#3115)
This commit is contained in:
parent
10c511a0e2
commit
e7bc9ba23c
1 changed files with 4 additions and 0 deletions
|
|
@ -283,6 +283,10 @@ void read_ce_cross_sections_xml()
|
|||
{
|
||||
// Check if cross_sections.xml exists
|
||||
const auto& filename = settings::path_cross_sections;
|
||||
if (dir_exists(filename)) {
|
||||
fatal_error("OPENMC_CROSS_SECTIONS is set to a directory. "
|
||||
"It should be set to an XML file.");
|
||||
}
|
||||
if (!file_exists(filename)) {
|
||||
// Could not find cross_sections.xml file
|
||||
fatal_error("Cross sections XML file '" + filename + "' does not exist.");
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue