mirror of
https://github.com/OPM/ResInsight.git
synced 2026-10-15 01:42:13 -05:00
Guard nullpointer access
This commit is contained in:
1 parent
805df93aed
commit
86bdf5722a
1 file changed
+1
-1
@@ -160,7 +160,7 @@ RimWellPath* RicWellLogTools::selectedWellPathWithLogFile()
|
||||
RimWellPath* RicWellLogTools::findWellPathWithLogFileFromSelection()
|
||||
{
|
||||
RimWellPath* wellPath = caf::SelectionManager::instance()->selectedItemAncestorOfType<RimWellPath>();
|
||||
if ( wellPath->wellLogFiles().size() > 0 )
|
||||
if ( wellPath && wellPath->wellLogFiles().size() > 0 )
|
||||
{
|
||||
return wellPath;
|
||||
}
|
||||
|
||||
Reference in new issue
Block a user