forked from qt-creator/qt-creator
QmlJS: Fix crash in PathsAndLanguages::compact()
Task-number: QTCREATORBUG-13786 Change-Id: If8c84714382c751f51315d62e1d4b0764e4431ff Reviewed-by: Fawzi Mohamed <fawzi.mohamed@theqtcompany.com>
This commit is contained in:
@@ -300,7 +300,11 @@ bool PathsAndLanguages::maybeInsert(const PathAndLanguage &pathAndLanguage) {
|
|||||||
return true;
|
return true;
|
||||||
}
|
}
|
||||||
|
|
||||||
void PathsAndLanguages::compact() {
|
void PathsAndLanguages::compact()
|
||||||
|
{
|
||||||
|
if (m_list.isEmpty())
|
||||||
|
return;
|
||||||
|
|
||||||
int oldCompactionPlace = 0;
|
int oldCompactionPlace = 0;
|
||||||
Utils::FileName oldPath = m_list.first().path();
|
Utils::FileName oldPath = m_list.first().path();
|
||||||
QList<PathAndLanguage> compactedList;
|
QList<PathAndLanguage> compactedList;
|
||||||
|
Reference in New Issue
Block a user