aboutsummaryrefslogtreecommitdiffstats
path: root/src
diff options
context:
space:
mode:
authorTim Blechmann <tim@klingt.org>2016-02-23 00:25:20 +0800
committerTim Blechmann <tim@klingt.org>2016-02-24 12:34:16 +0000
commit517d7eadaa8bd7dbc61f9247e8f67ee5eac493a9 (patch)
treefd16eb2deed4945355b5d3cefb576931323ed491 /src
parent029003851b5f9f5062385884d5591c46c4ebb1d2 (diff)
QQuickAnimatedSprite: fix memory leak
the QSGGeometryNode owns the geometry, so we need to set the flag to avoid a memory leak Change-Id: Ifaf1e88c437b765a76d7ab4028c63d66413440bb Reviewed-by: Jan Arve Sæther <jan-arve.saether@theqtcompany.com>
Diffstat (limited to 'src')
-rw-r--r--src/quick/items/qquickanimatedsprite.cpp1
1 files changed, 1 insertions, 0 deletions
diff --git a/src/quick/items/qquickanimatedsprite.cpp b/src/quick/items/qquickanimatedsprite.cpp
index e37ed6c18c..5f77c6461f 100644
--- a/src/quick/items/qquickanimatedsprite.cpp
+++ b/src/quick/items/qquickanimatedsprite.cpp
@@ -538,6 +538,7 @@ QSGGeometryNode* QQuickAnimatedSprite::buildNode()
m_node->setGeometry(g);
m_node->setMaterial(m_material);
m_node->setFlag(QSGGeometryNode::OwnsMaterial);
+ m_node->setFlag(QSGGeometryNode::OwnsGeometry);
sizeVertices();
return m_node;
}