summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorXisco Fauli <xiscofauli@libreoffice.org>2018-02-05 16:51:59 +0100
committerMarkus Mohrhard <markus.mohrhard@googlemail.com>2018-02-08 22:59:17 +0100
commit392206f0449f9baa987d28cf509eccfa33700330 (patch)
treea274af0af1ee0f9be9e2fcb3095062e110939538
parentb2dff7114d0be7ff1c9a9176c2f3bff1d52d84d1 (diff)
tdf#112990: Hack-around: Do not crash on mac with opengl enabled
Change-Id: Id8d1ffe593fa42b7e37e26e8d66ffad87d6685c1 Reviewed-on: https://gerrit.libreoffice.org/49251 Tested-by: Jenkins <ci@libreoffice.org> Reviewed-by: Tamás Bunth <btomi96@gmail.com> (cherry picked from commit c83d2ac99dc3da4ef85b193543a93e02e3858844) Reviewed-on: https://gerrit.libreoffice.org/49442 Reviewed-by: Markus Mohrhard <markus.mohrhard@googlemail.com>
-rw-r--r--vcl/source/outdev/text.cxx9
1 files changed, 9 insertions, 0 deletions
diff --git a/vcl/source/outdev/text.cxx b/vcl/source/outdev/text.cxx
index 1d93f7730aae..5694a8165b58 100644
--- a/vcl/source/outdev/text.cxx
+++ b/vcl/source/outdev/text.cxx
@@ -32,6 +32,7 @@
#include <vcl/sysdata.hxx>
#include <vcl/unohelp.hxx>
#include <vcl/controllayout.hxx>
+#include <vcl/opengl/OpenGLHelper.hxx>
#include <outdata.hxx>
#include <outdev.h>
@@ -861,6 +862,14 @@ void OutputDevice::DrawText( const Point& rStartPt, const OUString& rStr,
if(mpFontInstance->mpConversion)
pLayoutCache = nullptr;
+ #ifdef MACOSX
+ // FIXME: tdf#112990
+ // Cache text layout crashes on mac with OpenGL enabled
+ // Force it to not use the cache
+ if(OpenGLHelper::isVCLOpenGLEnabled())
+ pLayoutCache = nullptr;
+ #endif
+
// without cache
if(!pLayoutCache)
{