Fix crashes when reading an odb file fails due to corruption

This commit is contained in:
Jacob Støren
2018-04-23 16:35:19 +02:00
parent 51fb8a6935
commit 54c7932806
5 changed files with 36 additions and 14 deletions
@@ -147,6 +147,8 @@ void RimCellRangeFilter::setDefaultValues()
const cvf::StructGridInterface* grid = selectedGrid();
if (!grid) return;
Rim3dView* rimView = nullptr;
this->firstAncestorOrThisOfTypeAsserted(rimView);
RigActiveCellInfo* actCellInfo = RigReservoirGridTools::activeCellInfo(rimView);
@@ -208,6 +210,8 @@ void RimCellRangeFilter::defineEditorAttribute(const caf::PdmFieldHandle* field,
}
const cvf::StructGridInterface* grid = selectedGrid();
if (!grid) return;
if (field == &startIndexI || field == &cellCountI)
{