Guard recursive updates if NNC data import is disabled

Import of NNC data can be turned off in Preferences. If this is off, loading of projects using NNC data can enter a recursive update loop.
This commit is contained in:
Magne Sjaastad 2022-12-16 15:29:14 +01:00
parent 4e51516a96
commit 529c9af9a4

View File

@ -201,6 +201,9 @@ bool RigNNCData::ensureAllConnectionDataIsProcessed()
{
if ( m_haveGeneratedConnections ) return false;
// Return false if we have no data to process to avoid recursive updates in consuming code
if ( !m_mainGrid ) return false;
if ( m_mainGrid )
{
caf::ProgressInfo progressInfo( 3, "Computing NNC Data" );