Kaydet (Commit) 3ca14117 authored tarafından Michael Meeks's avatar Michael Meeks

fdo#62155 - don't crash if we can't create an instance of a calc addin.

Change-Id: I478d7777949683a91e7adf9fa6b54e9d01ced676
üst 26f6ff08
......@@ -593,11 +593,19 @@ void ScUnoAddInCollection::LoadComponent( const ScUnoAddInFuncData& rFuncData )
{
OUString aServiceName = aFullName.copy( 0, nPos );
uno::Reference<lang::XMultiServiceFactory> xServiceFactory = comphelper::getProcessServiceFactory();
uno::Reference<uno::XInterface> xInterface( xServiceFactory->createInstance( aServiceName ) );
try
{
uno::Reference<lang::XMultiServiceFactory> xServiceFactory = comphelper::getProcessServiceFactory();
uno::Reference<uno::XInterface> xInterface( xServiceFactory->createInstance( aServiceName ) );
if (xInterface.is())
UpdateFromAddIn( xInterface, aServiceName );
if (xInterface.is())
UpdateFromAddIn( xInterface, aServiceName );
}
catch (const uno::Exception &)
{
SAL_WARN ("sc", "Failed to create addin component '"
<< aServiceName << "'");
}
}
}
......
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment