From 6476ac738ca029af95932f53b53f0705808eb80e Mon Sep 17 00:00:00 2001 From: "Bradley T. Hughes" Date: Thu, 29 Sep 2011 11:50:08 +0200 Subject: Replace implicit QAtomic* casts with explicit load()/store() Change-Id: Ia7ef1a8e01001f203e409c710c977d6f4686342e Reviewed-by: Thiago Macieira --- src/opengl/qgl.cpp | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) (limited to 'src/opengl/qgl.cpp') diff --git a/src/opengl/qgl.cpp b/src/opengl/qgl.cpp index 38b8e44c0b..52b2ae329e 100644 --- a/src/opengl/qgl.cpp +++ b/src/opengl/qgl.cpp @@ -333,7 +333,7 @@ QGLFormat::QGLFormat(QGL::FormatOptions options, int plane) */ void QGLFormat::detach() { - if (d->ref != 1) { + if (d->ref.load() != 1) { QGLFormatPrivate *newd = new QGLFormatPrivate(d); if (!d->ref.deref()) delete d; @@ -4907,7 +4907,7 @@ void QGLContextGroup::addShare(const QGLContext *context, const QGLContext *shar return; // Make sure 'context' is not already shared with another group of contexts. - Q_ASSERT(context->d_ptr->group->m_refs == 1); + Q_ASSERT(context->d_ptr->group->m_refs.load() == 1); // Free 'context' group resources and make it use the same resources as 'share'. QGLContextGroup *group = share->d_ptr->group; -- cgit v1.2.3