summaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
authorGunnar Sletta <gunnar.sletta@nokia.com>2010-04-19 05:26:44 (GMT)
committerGunnar Sletta <gunnar.sletta@nokia.com>2010-04-19 08:29:34 (GMT)
commitc799eeffc43a186747f06a7d36a747cce59925dd (patch)
tree9b193419a2752692659507c7f9063f2e13eb641a
parentedc6e0218b5fad73476f1f18529b5ec48a3e100f (diff)
downloadQt-c799eeffc43a186747f06a7d36a747cce59925dd.zip
Qt-c799eeffc43a186747f06a7d36a747cce59925dd.tar.gz
Qt-c799eeffc43a186747f06a7d36a747cce59925dd.tar.bz2
Don't crash when calling drawPixmapFragements with a null pixmap
-rw-r--r--src/gui/painting/qpaintengineex.cpp3
1 files changed, 3 insertions, 0 deletions
diff --git a/src/gui/painting/qpaintengineex.cpp b/src/gui/painting/qpaintengineex.cpp
index 9366513..a78cafb 100644
--- a/src/gui/painting/qpaintengineex.cpp
+++ b/src/gui/painting/qpaintengineex.cpp
@@ -974,6 +974,9 @@ void QPaintEngineEx::drawTiledPixmap(const QRectF &r, const QPixmap &pixmap, con
void QPaintEngineEx::drawPixmapFragments(const QPainter::PixmapFragment *fragments, int fragmentCount,
const QPixmap &pixmap, QPainter::PixmapFragmentHints /*hints*/)
{
+ if (pixmap.isNull())
+ return;
+
qreal oldOpacity = state()->opacity;
QTransform oldTransform = state()->matrix;