vcl/skia/osx/gdiimpl.cxx | 5 +++++
1 file changed, 5 insertions(+)
New commits:
commit 82ed49b81eb0a45c25f3808a7d12efffffd5161a
Author: Patrick Luby <[email protected]>
AuthorDate: Wed Oct 11 14:36:12 2023 -0400
Commit: Patrick Luby <[email protected]>
CommitDate: Wed Oct 11 22:46:58 2023 +0200
tdf#157613 make sure surface is not a null pointer
Change-Id: I8e3c1be3f05f7ccc1f3ba00093cd71a564e5ae9e
Reviewed-on: https://gerrit.libreoffice.org/c/core/+/157848
Reviewed-by: Patrick Luby <[email protected]>
Tested-by: Patrick Luby <[email protected]>
diff --git a/vcl/skia/osx/gdiimpl.cxx b/vcl/skia/osx/gdiimpl.cxx
index 752208c0bc41..c4bd75184242 100644
--- a/vcl/skia/osx/gdiimpl.cxx
+++ b/vcl/skia/osx/gdiimpl.cxx
@@ -224,6 +224,11 @@ bool
AquaSkiaSalGraphicsImpl::drawNativeControl(ControlType nType, ControlPart n
const tools::Rectangle&
rControlRegion,
ControlState nState, const
ImplControlValue& aValue)
{
+ // tdf#157613 make sure surface is not a nullptr
+ checkSurface();
+ if (!mSurface)
+ return false;
+
// rControlRegion is not the whole area that the control should be painted
to (e.g. highlight
// around focused lineedit is outside of it). Since we draw to a temporary
bitmap, we need tofind out
// the real size. Using getNativeControlRegion() might seem like the
function to call, but we need