mirror of
https://github.com/OPM/ResInsight.git
synced 2026-10-16 18:32:10 -05:00
Guard null pointer access
This commit is contained in:
1 parent
49ef8c6f55
commit
451ce82aa9
1 file changed
+2
-1
@@ -1035,9 +1035,10 @@ cvf::ref<RivIntersectionHexGridInterface> RivIntersectionPartMgr::createHexGridI
|
||||
|
||||
RimGeoMechView* geoView;
|
||||
m_rimCrossSection->firstAncestorOrThisOfType(geoView);
|
||||
if (geoView)
|
||||
if (geoView && geoView->femParts() && geoView->femParts()->partCount())
|
||||
{
|
||||
RigFemPart* femPart = geoView->femParts()->part(0);
|
||||
|
||||
return new RivFemIntersectionGrid(femPart);
|
||||
}
|
||||
|
||||
|
||||
Reference in new issue
Block a user