diff options
author | Simon Hausmann <simon.hausmann@digia.com> | 2014-02-27 13:06:10 +0100 |
---|---|---|
committer | The Qt Project <gerrit-noreply@qt-project.org> | 2014-03-02 17:11:28 +0100 |
commit | 52dc3f6937d51046424b232323189dfb41cc09c7 (patch) | |
tree | b74c0e6bb30f7dcec9e599b88dd9b7637db7914c /src/qml/qml/qqmltypeloader.cpp | |
parent | 5c9a0f61c74724d571b56bdbac486594066ff5e8 (diff) |
[new compiler] Fix tst_qqmlengine::trimComponentCache
Fix bug in QQmlCompiledData refcounting.
Change-Id: I09528419c602d3173db2f13c516d2f0d79abd92e
Reviewed-by: Lars Knoll <lars.knoll@digia.com>
Diffstat (limited to 'src/qml/qml/qqmltypeloader.cpp')
-rw-r--r-- | src/qml/qml/qqmltypeloader.cpp | 6 |
1 files changed, 6 insertions, 0 deletions
diff --git a/src/qml/qml/qqmltypeloader.cpp b/src/qml/qml/qqmltypeloader.cpp index 75f983d9e8..c1074e8a84 100644 --- a/src/qml/qml/qqmltypeloader.cpp +++ b/src/qml/qml/qqmltypeloader.cpp @@ -1975,6 +1975,12 @@ QQmlTypeData::~QQmlTypeData() m_scripts.at(ii).script->release(); for (int ii = 0; ii < m_types.count(); ++ii) if (m_types.at(ii).typeData) m_types.at(ii).typeData->release(); + for (QHash<int, TypeReference>::ConstIterator it = m_resolvedTypes.constBegin(), end = m_resolvedTypes.constEnd(); + it != end; ++it) { + if (QQmlTypeData *tdata = it->typeData) + tdata->release(); + } + if (m_compiledData) m_compiledData->release(); delete m_implicitImport; |