[Libreoffice-commits] core.git: svx/source
Noel Grandin (via logerrit)
logerrit at kemper.freedesktop.org
Tue Jun 18 06:08:31 UTC 2019
svx/source/core/extedit.cxx | 5 +++--
svx/source/core/graphichelper.cxx | 6 +++---
svx/source/fmcomp/fmgridcl.cxx | 4 ++--
svx/source/fmcomp/gridcell.cxx | 4 ++--
svx/source/form/fmsrcimp.cxx | 9 ++-------
svx/source/gallery2/galtheme.cxx | 13 +++++++------
svx/source/gengal/gengal.cxx | 5 +++--
svx/source/svdraw/svdoole2.cxx | 4 ++--
8 files changed, 24 insertions(+), 26 deletions(-)
New commits:
commit 4079282731cdf276715af6571786ab75845efc15
Author: Noel Grandin <noel.grandin at collabora.co.uk>
AuthorDate: Mon Jun 17 08:22:14 2019 +0200
Commit: Noel Grandin <noel.grandin at collabora.co.uk>
CommitDate: Tue Jun 18 08:06:53 2019 +0200
loplugin:logexceptionnicely in svx
Change-Id: I741cf5befbec0c2ab353baae4865722ede993c2e
Reviewed-on: https://gerrit.libreoffice.org/74143
Tested-by: Jenkins
Reviewed-by: Noel Grandin <noel.grandin at collabora.co.uk>
diff --git a/svx/source/core/extedit.cxx b/svx/source/core/extedit.cxx
index 0c95811e744c..e1d31771c06d 100644
--- a/svx/source/core/extedit.cxx
+++ b/svx/source/core/extedit.cxx
@@ -28,6 +28,7 @@
#include <osl/process.h>
#include <osl/time.h>
#include <svtools/filechangedchecker.hxx>
+#include <tools/diagnose_ex.h>
#include <unotools/ucbstreamhelper.hxx>
#include <comphelper/processfactory.hxx>
@@ -95,9 +96,9 @@ void ExternalToolEditThread::execute()
xSystemShellExecute->execute(m_aFileName, OUString(),
SystemShellExecuteFlags::URIS_ONLY);
}
- catch (Exception const& e)
+ catch (Exception const&)
{
- SAL_WARN("svx", "ExternalToolEditThread: " << e);
+ TOOLS_WARN_EXCEPTION("svx", "ExternalToolEditThread");
}
}
diff --git a/svx/source/core/graphichelper.cxx b/svx/source/core/graphichelper.cxx
index a491e8210860..e3e2ed241e8a 100644
--- a/svx/source/core/graphichelper.cxx
+++ b/svx/source/core/graphichelper.cxx
@@ -26,7 +26,7 @@
#include <svx/graphichelper.hxx>
#include <svx/strings.hrc>
#include <sal/log.hxx>
-
+#include <tools/diagnose_ex.h>
#include <vcl/svapp.hxx>
#include <vcl/weld.hxx>
@@ -173,9 +173,9 @@ bool lcl_ExecuteFilterDialog( const Sequence< PropertyValue >& rPropsForDialog,
{
throw;
}
- catch( const Exception& e )
+ catch( const Exception& )
{
- SAL_WARN("sfx.doc", "ignoring " << e);
+ TOOLS_WARN_EXCEPTION("sfx.doc", "ignoring");
}
return bStatus;
diff --git a/svx/source/fmcomp/fmgridcl.cxx b/svx/source/fmcomp/fmgridcl.cxx
index e4d4bf6e010b..757a9142ae57 100644
--- a/svx/source/fmcomp/fmgridcl.cxx
+++ b/svx/source/fmcomp/fmgridcl.cxx
@@ -1887,8 +1887,8 @@ namespace
{
try {
xProp->getPropertyValue( _sPropName ) >>= sRetText;
- } catch (UnknownPropertyException const& e) {
- SAL_WARN("svx.fmcomp", e);
+ } catch (UnknownPropertyException const&) {
+ TOOLS_WARN_EXCEPTION("svx.fmcomp", "");
}
}
}
diff --git a/svx/source/fmcomp/gridcell.cxx b/svx/source/fmcomp/gridcell.cxx
index 7cb4a87cd4d0..622a22c4682a 100644
--- a/svx/source/fmcomp/gridcell.cxx
+++ b/svx/source/fmcomp/gridcell.cxx
@@ -3562,9 +3562,9 @@ void FmXTextCell::PaintFieldToCell(OutputDevice& rDev,
else
rDev.DrawText(rRect, aText, nStyle);
}
- catch (const Exception& e)
+ catch (const Exception&)
{
- SAL_WARN("svx.fmcomp", "PaintFieldToCell: caught " << e);
+ TOOLS_WARN_EXCEPTION("svx.fmcomp", "PaintFieldToCell");
}
}
diff --git a/svx/source/form/fmsrcimp.cxx b/svx/source/form/fmsrcimp.cxx
index f9eedbd65dbd..ae1803c9d85b 100644
--- a/svx/source/form/fmsrcimp.cxx
+++ b/svx/source/form/fmsrcimp.cxx
@@ -214,14 +214,9 @@ bool FmSearchEngine::MoveCursor()
else
m_xSearchCursor.previous();
}
- catch(css::sdbc::SQLException const& e)
+ catch(Exception const&)
{
- SAL_WARN( "svx", "FmSearchEngine::MoveCursor: caught " << e << " sqlstate=" << e.SQLState );
- bSuccess = false;
- }
- catch(Exception const& e)
- {
- SAL_WARN( "svx", "FmSearchEngine::MoveCursor: caught " << e);
+ TOOLS_WARN_EXCEPTION( "svx", "FmSearchEngine::MoveCursor");
bSuccess = false;
}
catch(...)
diff --git a/svx/source/gallery2/galtheme.cxx b/svx/source/gallery2/galtheme.cxx
index 227465c4da99..5875abd76bbd 100644
--- a/svx/source/gallery2/galtheme.cxx
+++ b/svx/source/gallery2/galtheme.cxx
@@ -28,6 +28,7 @@
#include <comphelper/processfactory.hxx>
#include <osl/file.hxx>
#include <osl/thread.hxx>
+#include <tools/diagnose_ex.h>
#include <tools/urlobj.hxx>
#include <tools/vcompat.hxx>
#include <unotools/streamwrap.hxx>
@@ -98,11 +99,11 @@ void GalleryTheme::ImplCreateSvDrawStorage()
if ( ( aSvDrawStorageRef->GetError() != ERRCODE_NONE ) && !pThm->IsReadOnly() )
aSvDrawStorageRef = new SotStorage( false, GetSdvURL().GetMainURL( INetURLObject::DecodeMechanism::NONE ), StreamMode::READ );
}
- catch (const css::ucb::ContentCreationException& e)
+ catch (const css::ucb::ContentCreationException&)
{
- SAL_WARN("svx", "failed to open: "
+ TOOLS_WARN_EXCEPTION("svx", "failed to open: "
<< GetSdvURL().GetMainURL(INetURLObject::DecodeMechanism::NONE)
- << "due to : " << e);
+ << "due to");
}
}
@@ -625,11 +626,11 @@ void GalleryTheme::Actualize( const Link<const INetURLObject&, void>& rActualize
aSvDrawStorageRef->CopyTo( aTempStorageRef.get() );
nStorErr = aSvDrawStorageRef->GetError();
}
- catch (const css::ucb::ContentCreationException& e)
+ catch (const css::ucb::ContentCreationException&)
{
- SAL_WARN("svx", "failed to open: "
+ TOOLS_WARN_EXCEPTION("svx", "failed to open: "
<< aTmpURL.GetMainURL(INetURLObject::DecodeMechanism::NONE)
- << "due to : " << e);
+ << "due to");
nStorErr = ERRCODE_IO_GENERAL;
}
diff --git a/svx/source/gengal/gengal.cxx b/svx/source/gengal/gengal.cxx
index 304b22b11b47..90304bea0d14 100644
--- a/svx/source/gengal/gengal.cxx
+++ b/svx/source/gengal/gengal.cxx
@@ -34,6 +34,7 @@
#include <rtl/bootstrap.hxx>
#include <sfx2/app.hxx>
#include <sal/types.h>
+#include <tools/diagnose_ex.h>
#include <vcl/svapp.hxx>
#include <svx/galtheme.hxx>
@@ -297,9 +298,9 @@ int GalApp::Main()
createTheme( aName, aPath, aDestDir, aFiles, mbRelativeURLs );
}
- catch (const uno::Exception& e)
+ catch (const uno::Exception&)
{
- SAL_WARN("svx", "Fatal: " << e);
+ TOOLS_WARN_EXCEPTION("svx", "Fatal");
return EXIT_FAILURE;
}
catch (const std::exception &e)
diff --git a/svx/source/svdraw/svdoole2.cxx b/svx/source/svdraw/svdoole2.cxx
index ceca9e1ef5ea..a795f07650da 100644
--- a/svx/source/svdraw/svdoole2.cxx
+++ b/svx/source/svdraw/svdoole2.cxx
@@ -950,9 +950,9 @@ void SdrOle2Obj::CheckFileLink_Impl()
}
}
}
- catch (const css::uno::Exception& e)
+ catch (const css::uno::Exception&)
{
- SAL_WARN("svx", "SdrOle2Obj::CheckFileLink_Impl(), " << e);
+ TOOLS_WARN_EXCEPTION("svx", "SdrOle2Obj::CheckFileLink_Impl()");
}
}
}
More information about the Libreoffice-commits
mailing list