forked from qt-creator/qt-creator
Fix crash in QMakeStep::allArguments
qtVersion can be null now
This commit is contained in:
@@ -137,10 +137,14 @@ QString QMakeStep::allArguments(bool shorted)
|
||||
|
||||
if (!haveSpec) {
|
||||
const QString tcSpec = bc->toolChain() ? bc->toolChain()->mkspec() : QString();
|
||||
if (!tcSpec.isEmpty() && bc->qtVersion()->hasMkspec(tcSpec))
|
||||
arguments << "-spec" << tcSpec;
|
||||
else
|
||||
if (tcSpec.isEmpty()) {
|
||||
if (bc->qtVersion())
|
||||
arguments << "-spec" << bc->qtVersion()->mkspec();
|
||||
} else if (!bc->qtVersion() || bc->qtVersion()->hasMkspec(tcSpec)) {
|
||||
arguments << "-spec" << tcSpec;
|
||||
} else {
|
||||
arguments << "-spec" << bc->qtVersion()->mkspec();
|
||||
}
|
||||
}
|
||||
|
||||
// Find out what flags we pass on to qmake
|
||||
|
||||
Reference in New Issue
Block a user