mirror of
https://github.com/OPM/ResInsight.git
synced 2025-02-25 18:55:39 -06:00
Check for valid index before accessing data
p4#: 21957
This commit is contained in:
parent
5db88f4e03
commit
c8a537e180
@ -252,6 +252,11 @@ void RigSingleWellResultsData::computeStaticWellCellPath()
|
||||
|
||||
for (bIt = staticWellBranches.begin(); bIt != staticWellBranches.end(); ++bIt)
|
||||
{
|
||||
if (bIt->first >= m_wellCellsTimeSteps[0].m_wellResultBranches.size())
|
||||
{
|
||||
continue;
|
||||
}
|
||||
|
||||
// Copy from first time step
|
||||
RigWellResultBranch rigBranch = m_wellCellsTimeSteps[0].m_wellResultBranches[bIt->first];
|
||||
rigBranch.m_branchIndex = bIt->first;
|
||||
|
Loading…
Reference in New Issue
Block a user