Fixes: Don't crash if we don't get any toolchain.

Details:  Stupid me.
This commit is contained in:
dt
2009-02-12 12:39:19 +01:00
parent 8b9dd766c8
commit 113723bb0e

View File

@@ -457,8 +457,12 @@ void Qt4Project::updateCodeModel()
const QString newQtLibsPath = versionInfo.value(QLatin1String("QT_INSTALL_LIBS"));
ToolChain *tc = toolChain(activeBuildConfiguration());
QByteArray predefinedMacros = tc->predefinedMacros();
QList<HeaderPath> allHeaderPaths = tc->systemHeaderPaths();
QByteArray predefinedMacros;
QList<HeaderPath> allHeaderPaths;
if (tc) {
predefinedMacros = tc->predefinedMacros();
allHeaderPaths = tc->systemHeaderPaths();
}
foreach (HeaderPath headerPath, allHeaderPaths) {
if (headerPath.kind() == HeaderPath::FrameworkHeaderPath)
allFrameworkPaths.append(headerPath.path());