summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
-rw-r--r--scripting/Library_protocolhandler.mk1
-rw-r--r--scripting/source/protocolhandler/scripthandler.cxx13
-rw-r--r--scripting/source/provider/BrowseNodeFactoryImpl.cxx4
-rw-r--r--scripting/source/provider/MasterScriptProvider.cxx10
-rw-r--r--scripting/source/vbaevents/eventhelper.cxx5
-rw-r--r--sd/source/filter/xml/sdxmlwrp.cxx4
-rw-r--r--sdext/source/pdfimport/filterdet.cxx5
-rw-r--r--sdext/source/pdfimport/pdfiadaptor.cxx5
-rw-r--r--sdext/source/pdfimport/test/pdf2xml.cxx5
9 files changed, 28 insertions, 24 deletions
diff --git a/scripting/Library_protocolhandler.mk b/scripting/Library_protocolhandler.mk
index e140bb322008..3d243f7f849b 100644
--- a/scripting/Library_protocolhandler.mk
+++ b/scripting/Library_protocolhandler.mk
@@ -27,6 +27,7 @@ $(eval $(call gb_Library_use_libraries,protocolhandler,\
fwe \
sal \
sfx \
+ tl \
vcl \
))
diff --git a/scripting/source/protocolhandler/scripthandler.cxx b/scripting/source/protocolhandler/scripthandler.cxx
index 07c4353893d6..dff0f3513e4b 100644
--- a/scripting/source/protocolhandler/scripthandler.cxx
+++ b/scripting/source/protocolhandler/scripthandler.cxx
@@ -158,12 +158,11 @@ void SAL_CALL ScriptProtocolHandler::dispatchWithNotification(
{
xListener->dispatchFinished( aEvent ) ;
}
- catch(RuntimeException & e)
+ catch(const RuntimeException &)
{
- SAL_WARN("scripting",
+ TOOLS_WARN_EXCEPTION("scripting",
"ScriptProtocolHandler::dispatchWithNotification: caught RuntimeException"
- "while dispatchFinished with failure of the execution "
- << e );
+ "while dispatchFinished with failure of the execution");
}
}
return;
@@ -285,11 +284,11 @@ void SAL_CALL ScriptProtocolHandler::dispatchWithNotification(
{
xListener->dispatchFinished( aEvent ) ;
}
- catch(const RuntimeException & e)
+ catch(const RuntimeException &)
{
- SAL_WARN("scripting",
+ TOOLS_WARN_EXCEPTION("scripting",
"ScriptProtocolHandler::dispatchWithNotification: caught RuntimeException"
- "while dispatchFinished " << e );
+ "while dispatchFinished" );
}
}
}
diff --git a/scripting/source/provider/BrowseNodeFactoryImpl.cxx b/scripting/source/provider/BrowseNodeFactoryImpl.cxx
index d3fc898086b8..909443f5f511 100644
--- a/scripting/source/provider/BrowseNodeFactoryImpl.cxx
+++ b/scripting/source/provider/BrowseNodeFactoryImpl.cxx
@@ -282,9 +282,9 @@ std::vector< Reference< browse::XBrowseNode > > getAllBrowseNodes( const Referen
locnBNs[ mspIndex++ ].set( xFac->createScriptProvider( makeAny( OUString("share") ) ), UNO_QUERY_THROW );
}
// TODO proper exception handling, should throw
- catch( const Exception& e )
+ catch( const Exception& )
{
- SAL_WARN("scripting", "Caught " << e );
+ TOOLS_WARN_EXCEPTION("scripting", "Caught" );
locnBNs.resize( mspIndex );
return locnBNs;
}
diff --git a/scripting/source/provider/MasterScriptProvider.cxx b/scripting/source/provider/MasterScriptProvider.cxx
index 8daa183d5ec8..fe2d074c4632 100644
--- a/scripting/source/provider/MasterScriptProvider.cxx
+++ b/scripting/source/provider/MasterScriptProvider.cxx
@@ -209,10 +209,10 @@ void MasterScriptProvider::createPkgProvider()
xFac->createScriptProvider( location ), UNO_SET_THROW );
}
- catch ( const Exception& e )
+ catch ( const Exception& )
{
- SAL_WARN("scripting.provider", "Exception creating MasterScriptProvider for uno_packages in context "
- << m_sCtxString << ": " << e );
+ TOOLS_WARN_EXCEPTION("scripting.provider", "Exception creating MasterScriptProvider for uno_packages in context "
+ << m_sCtxString );
}
}
@@ -470,9 +470,9 @@ template <typename Proc> bool FindProviderAndApply(ProviderCache& rCache, Proc p
if (bResult)
break;
}
- catch (Exception& e)
+ catch (const Exception&)
{
- SAL_INFO("scripting.provider", "ignoring " << e);
+ TOOLS_INFO_EXCEPTION("scripting.provider", "ignoring");
}
}
return bResult;
diff --git a/scripting/source/vbaevents/eventhelper.cxx b/scripting/source/vbaevents/eventhelper.cxx
index 21a52e9b28c4..8388450aa2b2 100644
--- a/scripting/source/vbaevents/eventhelper.cxx
+++ b/scripting/source/vbaevents/eventhelper.cxx
@@ -23,6 +23,7 @@
#include <comphelper/uno3.hxx>
#include <comphelper/proparrhlp.hxx>
#include <comphelper/propertycontainer.hxx>
+#include <tools/diagnose_ex.h>
#include <ooo/vba/XVBAToOOEventDescGen.hpp>
@@ -909,9 +910,9 @@ EventListener::firing_Impl(const ScriptEvent& evt, Any* pRet )
ooo::vba::executeMacro( mpShell, url, aArguments, aRet, aDummyCaller );
}
}
- catch ( uno::Exception& e )
+ catch ( const uno::Exception& )
{
- SAL_WARN("scripting", "event script raised " << e );
+ TOOLS_WARN_EXCEPTION("scripting", "event script raised" );
}
}
}
diff --git a/sd/source/filter/xml/sdxmlwrp.cxx b/sd/source/filter/xml/sdxmlwrp.cxx
index 3c9cf80ab33b..e6e5adb26c4d 100644
--- a/sd/source/filter/xml/sdxmlwrp.cxx
+++ b/sd/source/filter/xml/sdxmlwrp.cxx
@@ -1005,9 +1005,9 @@ bool SdXMLFilter::Export()
mxStatusIndicator->end();
}
}
- catch (const uno::Exception &e)
+ catch (const uno::Exception &)
{
- SAL_WARN( "sd.filter", "uno Exception caught while exporting:" << e);
+ TOOLS_WARN_EXCEPTION( "sd.filter", "uno Exception caught while exporting");
bDocRet = false;
}
if ( !bLocked )
diff --git a/sdext/source/pdfimport/filterdet.cxx b/sdext/source/pdfimport/filterdet.cxx
index a726ef883e3c..4b72c932f44c 100644
--- a/sdext/source/pdfimport/filterdet.cxx
+++ b/sdext/source/pdfimport/filterdet.cxx
@@ -36,6 +36,7 @@
#include <comphelper/fileurl.hxx>
#include <comphelper/hash.hxx>
#include <cppuhelper/supportsservice.hxx>
+#include <tools/diagnose_ex.h>
#include <memory>
#include <string.h>
@@ -290,8 +291,8 @@ OUString SAL_CALL PDFDetector::detect( uno::Sequence< beans::PropertyValue >& rF
}
osl_closeFile( aFile );
}
- } catch (css::io::IOException & e) {
- SAL_WARN("sdext.pdfimport", "caught " << e);
+ } catch (const css::io::IOException &) {
+ TOOLS_WARN_EXCEPTION("sdext.pdfimport", "caught");
return OUString();
}
OUString aEmbedMimetype;
diff --git a/sdext/source/pdfimport/pdfiadaptor.cxx b/sdext/source/pdfimport/pdfiadaptor.cxx
index cd8c67b24ab1..e66cf59f7f79 100644
--- a/sdext/source/pdfimport/pdfiadaptor.cxx
+++ b/sdext/source/pdfimport/pdfiadaptor.cxx
@@ -39,6 +39,7 @@
#include <com/sun/star/io/XInputStream.hpp>
#include <com/sun/star/xml/sax/XDocumentHandler.hpp>
#include <com/sun/star/io/XSeekable.hpp>
+#include <tools/diagnose_ex.h>
#include <memory>
@@ -153,9 +154,9 @@ sal_Bool SAL_CALL PDFIHybridAdaptor::filter( const uno::Sequence< beans::Propert
m_xContext ),
uno::UNO_QUERY );
}
- catch(const uno::Exception& e)
+ catch(const uno::Exception&)
{
- SAL_INFO("sdext.pdfimport", "subfilter: " << e);
+ TOOLS_INFO_EXCEPTION("sdext.pdfimport", "subfilter");
}
SAL_INFO("sdext.pdfimport", "subfilter: " << xSubFilter.get() );
diff --git a/sdext/source/pdfimport/test/pdf2xml.cxx b/sdext/source/pdfimport/test/pdf2xml.cxx
index 5d8c06ca0294..04b5ee8d19c0 100644
--- a/sdext/source/pdfimport/test/pdf2xml.cxx
+++ b/sdext/source/pdfimport/test/pdf2xml.cxx
@@ -32,6 +32,7 @@
#include <unotest/bootstrapfixturebase.hxx>
#include <comphelper/processfactory.hxx>
#include <cppuhelper/bootstrap.hxx>
+#include <tools/diagnose_ex.h>
using namespace ::pdfi;
using namespace ::com::sun::star;
@@ -80,9 +81,9 @@ SAL_IMPLEMENT_MAIN_WITH_ARGS(argc, argv)
xAdaptor->setTreeVisitorFactory(pTreeFactory);
nRet = xAdaptor->odfConvert(aSrcURL, new OutputWrap(aDstURL), nullptr) ? 0 : 1;
}
- catch (const uno::Exception& e)
+ catch (const uno::Exception&)
{
- SAL_WARN("vcl.app", "Fatal: " << e);
+ TOOLS_WARN_EXCEPTION("vcl.app", "Fatal");
return 1;
}
catch (const std::exception& e)