From 003976f81b99deaae413bb04f823ca1e5419929d Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Sl=C3=A1vek=20Banko?= Date: Wed, 9 Mar 2022 22:29:17 +0100 Subject: [PATCH] tdehtml: Prevent a crash in case of a image that is not in cache. MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit Signed-off-by: Slávek Banko --- tdehtml/rendering/render_image.cpp | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/tdehtml/rendering/render_image.cpp b/tdehtml/rendering/render_image.cpp index 18bc62aed..4f3e87c99 100644 --- a/tdehtml/rendering/render_image.cpp +++ b/tdehtml/rendering/render_image.cpp @@ -241,7 +241,7 @@ void RenderImage::paint(PaintInfo& paintInfo, int _tx, int _ty) ? m_oldImage : m_cachedImage; // paint frame around image as long as it is not completely loaded from web. - if (bUnfinishedImageFrame && paintInfo.phase == PaintActionForeground && cWidth > 2 && cHeight > 2 && !complete() && !i->isVectorImage()) { + if (bUnfinishedImageFrame && paintInfo.phase == PaintActionForeground && cWidth > 2 && cHeight > 2 && !complete() && !(i && i->isVectorImage())) { static TQPixmap *loadingIcon; TQColor bg = tdehtml::retrieveBackgroundColor(this); TQColor fg = tdehtml::hasSufficientContrast(Qt::gray, bg) ? Qt::gray :