aboutsummaryrefslogtreecommitdiffhomepage
diff options
context:
space:
mode:
authorVaxry <[email protected]>2024-03-15 21:29:20 +0000
committerVaxry <[email protected]>2024-03-15 21:29:20 +0000
commit2a2da6082e5f1501731004b755d35a8dbb605fde (patch)
tree6c62dc99ab32868b42928b836c190e35814a689f
parentc4f52d19792696b8b297877b9152bd86d0f4624b (diff)
downloadHyprland-2a2da6082e5f1501731004b755d35a8dbb605fde.tar.gz
Hyprland-2a2da6082e5f1501731004b755d35a8dbb605fde.zip
renderer: fix invalid access on non-assigned surfaces
fixes #5125
-rw-r--r--src/render/Renderer.cpp2
1 files changed, 1 insertions, 1 deletions
diff --git a/src/render/Renderer.cpp b/src/render/Renderer.cpp
index 2a0c6f7d..5c0d3d10 100644
--- a/src/render/Renderer.cpp
+++ b/src/render/Renderer.cpp
@@ -75,7 +75,7 @@ static void renderSurface(struct wlr_surface* surface, int x, int y, void* data)
// however, if surface buffer w / h < box, we need to adjust them
auto* const PSURFACE = CWLSurface::surfaceFromWlr(surface);
- const auto PWINDOW = PSURFACE->getWindow();
+ const auto PWINDOW = PSURFACE ? PSURFACE->getWindow() : nullptr;
if (PSURFACE && !PSURFACE->m_bFillIgnoreSmall && PSURFACE->small() /* guarantees PWINDOW */) {
const auto CORRECT = PSURFACE->correctSmallVec();