diff options
author | mread <qt-info@nokia.com> | 2011-08-26 12:30:53 (GMT) |
---|---|---|
committer | mread <qt-info@nokia.com> | 2011-08-26 12:30:53 (GMT) |
commit | 91096126440aafba22aeb9307cb72135b3156a4c (patch) | |
tree | f4f8c67d7d33320382f4f56d87e26dde842f2807 /src/declarative | |
parent | a4eae8a44ca38739755ba8994251e2b120878ec8 (diff) | |
download | Qt-91096126440aafba22aeb9307cb72135b3156a4c.zip Qt-91096126440aafba22aeb9307cb72135b3156a4c.tar.gz Qt-91096126440aafba22aeb9307cb72135b3156a4c.tar.bz2 |
Porting the QTBUG-21084 fix to 4.7.4
This fixes a memory leak. It's SR1 tagged for 4.7.4.
Task-number: QTBUG-21084
Reviewed-by: Honglei Zhang
Diffstat (limited to 'src/declarative')
-rw-r--r-- | src/declarative/util/qdeclarativelistmodel.cpp | 1 |
1 files changed, 1 insertions, 0 deletions
diff --git a/src/declarative/util/qdeclarativelistmodel.cpp b/src/declarative/util/qdeclarativelistmodel.cpp index d0c8cc8..92aa6d0 100644 --- a/src/declarative/util/qdeclarativelistmodel.cpp +++ b/src/declarative/util/qdeclarativelistmodel.cpp @@ -784,6 +784,7 @@ void QDeclarativeListModelParser::setCustomData(QObject *obj, const QByteArray & QDeclarativeListModel *rv = static_cast<QDeclarativeListModel *>(obj); ModelNode *root = new ModelNode(rv->m_nested); + rv->m_nested->m_ownsRoot = true; rv->m_nested->_root = root; QStack<ModelNode *> nodes; nodes << root; |