#13176 Use guarded pointers for highlighted curves

This commit is contained in:
Magne Sjaastad authored and Kristian Bendiksen committed 2025-11-14 13:06:32 +01:00
1 parent 7c8aadcd60
commit b6f0164de7
3 files changed
+17 -13

No files matched your search

@@ -1846,7 +1846,9 @@ void RimSummaryMultiPlot::updateReadOutLines( double qwtTimeValue, double yValue
{
for ( auto highlightCurve : plotWidget->highlightedCurves() )
{
if ( auto summaryCurve = dynamic_cast<RimSummaryCurve*>( highlightCurve ) )
if ( highlightCurve.isNull() ) continue;
if ( auto summaryCurve = dynamic_cast<RimSummaryCurve*>( highlightCurve.p() ) )
{
summaryCurves.push_back( summaryCurve );
}