From af77dff1c08313fd355d173eacff9267595f7087 Mon Sep 17 00:00:00 2001 From: Caolán McNamara Date: Mon, 11 Dec 2017 09:16:37 +0000 Subject: ofz#4583 Abrt MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit Change-Id: Id6e782cb09a76901cdd8c43b25eff3d53700ece7 Reviewed-on: https://gerrit.libreoffice.org/46216 Tested-by: Jenkins Reviewed-by: Caolán McNamara Tested-by: Caolán McNamara --- svx/source/svdraw/svdoashp.cxx | 13 ++++++++++--- 1 file changed, 10 insertions(+), 3 deletions(-) diff --git a/svx/source/svdraw/svdoashp.cxx b/svx/source/svdraw/svdoashp.cxx index bfc41acfd63c..11ba1cbbdf76 100644 --- a/svx/source/svdraw/svdoashp.cxx +++ b/svx/source/svdraw/svdoashp.cxx @@ -24,6 +24,7 @@ #include #include #include +#include #include #include #include @@ -424,9 +425,15 @@ Reference< XCustomShapeEngine > const & SdrObjCustomShape::GetCustomShapeEngine( aPropValues[ 0 ].Name = "CustomShape"; aPropValues[ 0 ].Value <<= aXShape; aArgument[ 0 ] <<= aPropValues; - Reference< XInterface > xInterface( xContext->getServiceManager()->createInstanceWithArgumentsAndContext( aEngine, aArgument, xContext ) ); - if ( xInterface.is() ) - mxCustomShapeEngine.set( xInterface, UNO_QUERY ); + try + { + Reference xInterface(xContext->getServiceManager()->createInstanceWithArgumentsAndContext(aEngine, aArgument, xContext)); + if (xInterface.is()) + mxCustomShapeEngine.set( xInterface, UNO_QUERY ); + } + catch (const css::loader::CannotActivateFactoryException&) + { + } } return mxCustomShapeEngine; -- cgit