#1257 Added null pointer guarding based on reports from CppCheck

This commit is contained in:
Magne Sjaastad
2017-02-24 16:00:56 +01:00
parent 85228ee39c
commit a29f6abc32
14 changed files with 81 additions and 50 deletions

View File

@@ -45,7 +45,7 @@ bool RicDeleteWellLogPlotTrackFeature::isCommandEnabled()
{
RimWellLogPlot* wellLogPlot = NULL;
selection[0]->firstAncestorOrThisOfType(wellLogPlot);
if (wellLogPlot->trackCount() > 1)
if (wellLogPlot && wellLogPlot->trackCount() > 1)
{
return true;
}