From d0c01c581a69649d189a4febea90be050100322f Mon Sep 17 00:00:00 2001 From: Friedemann Kleint Date: Thu, 26 Apr 2012 10:00:41 +0200 Subject: QtQuick1: Fix deprecation warnings. Introduced by qtbase:0df1c9f1fa04c06d6105de3f312c6c752a58ad70 Change-Id: I61e330707a49efd09bad0efda386712fba207c8a Reviewed-by: Alan Alpert --- src/imports/shaders/scenegraph/qsggeometry.cpp | 8 +++++--- 1 file changed, 5 insertions(+), 3 deletions(-) (limited to 'src/imports') diff --git a/src/imports/shaders/scenegraph/qsggeometry.cpp b/src/imports/shaders/scenegraph/qsggeometry.cpp index 7c8b876c..48f48374 100644 --- a/src/imports/shaders/scenegraph/qsggeometry.cpp +++ b/src/imports/shaders/scenegraph/qsggeometry.cpp @@ -41,6 +41,8 @@ #include "qsggeometry.h" +#include + QT_BEGIN_NAMESPACE @@ -101,7 +103,7 @@ QSGGeometry::QSGGeometry(const QSGGeometry::AttributeSet &attributes, QSGGeometry::~QSGGeometry() { if (m_owns_data) - qFree(m_data); + free(m_data); } void *QSGGeometry::indexData() @@ -135,7 +137,7 @@ void QSGGeometry::allocate(int vertexCount, int indexCount) int vertexByteSize = m_attributes.stride * m_vertex_count; if (m_owns_data) - qFree(m_data); + free(m_data); if (canUsePrealloc && vertexByteSize <= (int) sizeof(m_prealloc)) { m_data = (void *) &m_prealloc[0]; @@ -144,7 +146,7 @@ void QSGGeometry::allocate(int vertexCount, int indexCount) } else { Q_ASSERT(m_index_type == GL_UNSIGNED_INT || m_index_type == GL_UNSIGNED_SHORT); int indexByteSize = indexCount * (m_index_type == GL_UNSIGNED_SHORT ? sizeof(quint16) : sizeof(quint32)); - m_data = (void *) qMalloc(vertexByteSize + indexByteSize); + m_data = malloc(vertexByteSize + indexByteSize); m_index_data_offset = vertexByteSize; m_owns_data = true; } -- cgit v1.2.3