From 9ba195479ac3bc2c64d43ecf26f8c97e65483a5c Mon Sep 17 00:00:00 2001 From: Frederik Gladhorn Date: Wed, 14 May 2014 13:50:32 +0200 Subject: Fix copy and paste error Fix first error "Null pointer dereferencing" identified by static analysis from http://www.viva64.com/en/b/0251/ Change-Id: I984d6ac2c22fddfe5ccb507f5d95d3329bed0563 Reviewed-by: Simon Hausmann Reviewed-by: Lars Knoll --- src/quick/items/context2d/qquickcontext2d.cpp | 5 ----- 1 file changed, 5 deletions(-) diff --git a/src/quick/items/context2d/qquickcontext2d.cpp b/src/quick/items/context2d/qquickcontext2d.cpp index 29e83e8247..3481651b1e 100644 --- a/src/quick/items/context2d/qquickcontext2d.cpp +++ b/src/quick/items/context2d/qquickcontext2d.cpp @@ -3177,11 +3177,6 @@ QV4::ReturnedValue QQuickJSContext2DPixelData::getIndexed(QV4::Managed *m, uint QV4::ExecutionEngine *v4 = m->engine(); QV4::Scope scope(v4); QV4::Scoped r(scope, m->as()); - if (!m) { - if (hasProperty) - *hasProperty = false; - return m->engine()->currentContext()->throwTypeError(); - } if (r && index < static_cast(r->image.width() * r->image.height() * 4)) { if (hasProperty) -- cgit v1.2.3