mirror of
https://github.com/OPM/opm-simulators.git
synced 2025-02-25 18:55:30 -06:00
Use formattedErrors() and simplify.
No longer calling dump() means we avoid the extra dumping to stderr of the warnings and errors.
This commit is contained in:
@@ -617,10 +617,7 @@ void Opm::readDeck(Opm::Parallel::Communication comm,
|
|||||||
|
|
||||||
if (*errorGuard) { // errors encountered
|
if (*errorGuard) { // errors encountered
|
||||||
parseSuccess = 0;
|
parseSuccess = 0;
|
||||||
if (failureMessage.size()) {
|
failureMessage += errorGuard->formattedErrors();
|
||||||
failureMessage += std::string("\n");
|
|
||||||
}
|
|
||||||
failureMessage += errorGuard->dump();
|
|
||||||
errorGuard->clear();
|
errorGuard->clear();
|
||||||
}
|
}
|
||||||
|
|
||||||
@@ -628,7 +625,7 @@ void Opm::readDeck(Opm::Parallel::Communication comm,
|
|||||||
|
|
||||||
if (! parseSuccess) {
|
if (! parseSuccess) {
|
||||||
if (comm.rank() == 0) {
|
if (comm.rank() == 0) {
|
||||||
OpmLog::error(fmt::format("Unrecoverable errors while loading input: {}", failureMessage));
|
OpmLog::error(fmt::format("Unrecoverable errors while loading input:\n{}", failureMessage));
|
||||||
}
|
}
|
||||||
|
|
||||||
#if HAVE_MPI
|
#if HAVE_MPI
|
||||||
|
|||||||
Reference in New Issue
Block a user