Add additional assertion for OOM detection.

This commit is contained in:
John Preston 2023-04-22 21:35:06 +04:00
parent dffe79fea8
commit 4201a0193c
1 changed files with 1 additions and 0 deletions

View File

@ -850,6 +850,7 @@ void OverlayWidget::RendererGL::paintUsingRaster(
const auto size = rect.size() * _factor;
if (raster.width() < size.width() || raster.height() < size.height()) {
raster = QImage(size, QImage::Format_ARGB32_Premultiplied);
Assert(!raster.isNull());
raster.setDevicePixelRatio(_factor);
if (!transparent
&& (raster.width() > size.width()