diff --git a/src/plugins/qtsupport/exampleslistmodel.cpp b/src/plugins/qtsupport/exampleslistmodel.cpp index 83d1659a5f8..2a48449ef32 100644 --- a/src/plugins/qtsupport/exampleslistmodel.cpp +++ b/src/plugins/qtsupport/exampleslistmodel.cpp @@ -251,8 +251,11 @@ static QPixmap fetchPixmapAndUpdatePixmapCache(const QString &url) // boundedTo -> don't scale thumbnails up const QSize scaledSize = WelcomePageHelpers::GridItemImageSize.boundedTo(img.size()) * dpr; - pixmap = QPixmap::fromImage( - img.scaled(scaledSize, Qt::KeepAspectRatio, Qt::SmoothTransformation)); + const QImage scaled = img.isNull() ? img + : img.scaled(scaledSize, + Qt::KeepAspectRatio, + Qt::SmoothTransformation); + pixmap = QPixmap::fromImage(scaled); pixmap.setDevicePixelRatio(dpr); } } else {