diff --git a/src/blackgui/components/modelmatcherlogcomponent.cpp b/src/blackgui/components/modelmatcherlogcomponent.cpp index 6abb25af2..70c3c9ee6 100644 --- a/src/blackgui/components/modelmatcherlogcomponent.cpp +++ b/src/blackgui/components/modelmatcherlogcomponent.cpp @@ -66,7 +66,7 @@ namespace BlackGui void CModelMatcherLogComponent::ps_updateCallsignCompleter() { - if (!sGui || !sGui->getIContextNetwork()->isConnected()) { return; } + if (!sGui || !sGui->getIContextNetwork() || sGui->getIContextNetwork()->isEmptyObject() || !sGui->getIContextNetwork()->isConnected()) { return; } const QStringList callsigns = sGui->getIContextNetwork()->getAircraftInRangeCallsigns().toStringList(false); QCompleter *completer = ui->le_Callsign->completer(); diff --git a/src/blackmisc/simulation/xplane/xplaneutil.cpp b/src/blackmisc/simulation/xplane/xplaneutil.cpp index 872449b55..3cddd83e5 100644 --- a/src/blackmisc/simulation/xplane/xplaneutil.cpp +++ b/src/blackmisc/simulation/xplane/xplaneutil.cpp @@ -104,6 +104,7 @@ namespace BlackMisc QStringList CXPlaneUtil::xplaneModelDirectories() { + if (xplaneRootDir().isEmpty()) { return QStringList(); } return QStringList({ xplaneRootDir() }); }