Fix BakeAssetTask not handling case where oven process is not found

This commit is contained in:
Ryan Huffman 2017-12-08 17:45:42 -08:00
parent 982607eedf
commit 50c47c785d

View file

@ -115,7 +115,12 @@ void BakeAssetTask::run() {
qDebug() << "Starting oven for " << _assetPath;
_ovenProcess->start(path, args, QIODevice::ReadOnly);
_ovenProcess->waitForStarted();
if (!_ovenProcess->waitForStarted(-1)) {
_didFinish.store(true);
QString errors = "Oven process failed to start";
emit bakeFailed(_assetHash, _assetPath, errors);
return;
}
_ovenProcess->waitForFinished();
}