summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorLuboš Luňák <l.lunak@collabora.com>2020-10-06 14:51:21 +0200
committerLuboš Luňák <l.lunak@collabora.com>2020-10-06 14:51:56 +0200
commite1482daecff877e3b0e22f1fc864e614376cb6b1 (patch)
tree88aeb2b2665c7be4b068ec2bdb44674925618cc3
parent66ce7a7bcae0e0e38fc56f6780eec86e06acfd90 (diff)
add missing null pointer check
It's possible to trigger this case, and the windows variant already has the check. Change-Id: I465fbccb8910bd1b529a2639f34249c18289baa8
-rw-r--r--vcl/skia/x11/gdiimpl.cxx3
1 files changed, 2 insertions, 1 deletions
diff --git a/vcl/skia/x11/gdiimpl.cxx b/vcl/skia/x11/gdiimpl.cxx
index 9b93a603dc38..d993cf61d8d7 100644
--- a/vcl/skia/x11/gdiimpl.cxx
+++ b/vcl/skia/x11/gdiimpl.cxx
@@ -140,7 +140,8 @@ void X11SkiaSalGraphicsImpl::performFlush()
SkiaZone zone;
flushDrawing();
// TODO XPutImage() is somewhat inefficient, XShmPutImage() should be preferred.
- mWindowContext->swapBuffers();
+ if (mWindowContext)
+ mWindowContext->swapBuffers();
}
std::unique_ptr<sk_app::WindowContext> createVulkanWindowContext(bool temporary)