diff options
author | Noel Grandin <noelgrandin@gmail.com> | 2019-12-26 09:22:30 +0200 |
---|---|---|
committer | Noel Grandin <noel.grandin@collabora.co.uk> | 2019-12-26 19:08:42 +0100 |
commit | df773dc769f6a0d676673ac9b5fc0e8132e435e6 (patch) | |
tree | fe744b9d76e5f26282409fbe3b117e24659de7c0 /svx | |
parent | 32b9d07baa0cf6907f14ccb9aa068b51d95eefaa (diff) |
use more TOOLS_WARN_EXCEPTION
so we get more useful log messages when stuff goes wrong
Change-Id: Ia55db7ab1a4d79b0f281673fbbb06c61745fa89e
Reviewed-on: https://gerrit.libreoffice.org/c/core/+/85829
Tested-by: Jenkins
Reviewed-by: Noel Grandin <noel.grandin@collabora.co.uk>
Diffstat (limited to 'svx')
-rw-r--r-- | svx/source/accessibility/AccessibleControlShape.cxx | 5 | ||||
-rw-r--r-- | svx/source/dialog/weldeditview.cxx | 3 | ||||
-rw-r--r-- | svx/source/fmcomp/fmgridcl.cxx | 4 | ||||
-rw-r--r-- | svx/source/fmcomp/gridcell.cxx | 9 | ||||
-rw-r--r-- | svx/source/form/fmcontrolbordermanager.cxx | 7 | ||||
-rw-r--r-- | svx/source/form/fmcontrollayout.cxx | 2 | ||||
-rw-r--r-- | svx/source/form/fmdocumentclassification.cxx | 2 | ||||
-rw-r--r-- | svx/source/form/fmobjfac.cxx | 3 | ||||
-rw-r--r-- | svx/source/form/fmpgeimp.cxx | 2 | ||||
-rw-r--r-- | svx/source/form/fmshimp.cxx | 2 | ||||
-rw-r--r-- | svx/source/form/fmtextcontrolfeature.cxx | 7 | ||||
-rw-r--r-- | svx/source/form/fmtools.cxx | 3 | ||||
-rw-r--r-- | svx/source/form/fmundo.cxx | 12 | ||||
-rw-r--r-- | svx/source/form/formcontrolfactory.cxx | 2 | ||||
-rw-r--r-- | svx/source/form/formfeaturedispatcher.cxx | 2 | ||||
-rw-r--r-- | svx/source/form/formtoolbars.cxx | 3 | ||||
-rw-r--r-- | svx/source/form/navigatortree.cxx | 3 | ||||
-rw-r--r-- | svx/source/form/tabwin.cxx | 3 | ||||
-rw-r--r-- | svx/source/svdraw/svdouno.cxx | 2 | ||||
-rw-r--r-- | svx/source/tbxctrls/tbxcolor.cxx | 2 |
20 files changed, 41 insertions, 37 deletions
diff --git a/svx/source/accessibility/AccessibleControlShape.cxx b/svx/source/accessibility/AccessibleControlShape.cxx index 9b36c9b51263..647a75251036 100644 --- a/svx/source/accessibility/AccessibleControlShape.cxx +++ b/svx/source/accessibility/AccessibleControlShape.cxx @@ -50,6 +50,7 @@ #include <vcl/svapp.hxx> #include <sal/log.hxx> #include <tools/debug.hxx> +#include <tools/diagnose_ex.h> #include <algorithm> using namespace ::accessibility; @@ -682,7 +683,7 @@ bool AccessibleControlShape::ensureControlModelAccess() } catch( const Exception& ) { - OSL_FAIL( "AccessibleControlShape::ensureControlModelAccess: caught an exception!" ); + TOOLS_WARN_EXCEPTION( "svx", "AccessibleControlShape::ensureControlModelAccess" ); } return m_xControlModel.is(); @@ -738,7 +739,7 @@ OUString AccessibleControlShape::getControlModelStringProperty( const OUString& } catch( const Exception& ) { - OSL_FAIL( "OAccessibleControlContext::getModelStringProperty: caught an exception!" ); + TOOLS_WARN_EXCEPTION( "svx", "OAccessibleControlContext::getModelStringProperty" ); } return sReturn; } diff --git a/svx/source/dialog/weldeditview.cxx b/svx/source/dialog/weldeditview.cxx index 222a3db5747b..60887fc46f8c 100644 --- a/svx/source/dialog/weldeditview.cxx +++ b/svx/source/dialog/weldeditview.cxx @@ -37,6 +37,7 @@ #include <sal/log.hxx> #include <svx/AccessibleTextHelper.hxx> #include <svx/weldeditview.hxx> +#include <tools/diagnose_ex.h> #include <unotools/accessiblestatesethelper.hxx> #include <vcl/cursor.hxx> #include <vcl/event.hxx> @@ -593,7 +594,7 @@ public: } catch (const css::uno::Exception&) { - OSL_FAIL("WeldEditAccessible::getAccessibleIndexInParent: caught an exception!"); + TOOLS_WARN_EXCEPTION("svx", "WeldEditAccessible::getAccessibleIndexInParent"); } return nRet; diff --git a/svx/source/fmcomp/fmgridcl.cxx b/svx/source/fmcomp/fmgridcl.cxx index b2c9cd46b0a4..69574776f876 100644 --- a/svx/source/fmcomp/fmgridcl.cxx +++ b/svx/source/fmcomp/fmgridcl.cxx @@ -1483,7 +1483,7 @@ void FmGridControl::RowHeightChanged() } catch( const Exception& ) { - OSL_FAIL( "FmGridControl::RowHeightChanged: caught an exception!" ); + TOOLS_WARN_EXCEPTION( "svx", "FmGridControl::RowHeightChanged" ); } } } @@ -2051,7 +2051,7 @@ void FmGridControl::KeyInput( const KeyEvent& rKEvt ) } catch(const Exception&) { - OSL_FAIL("exception occurred while deleting a column"); + TOOLS_WARN_EXCEPTION("svx", "exception occurred while deleting a column"); } } } diff --git a/svx/source/fmcomp/gridcell.cxx b/svx/source/fmcomp/gridcell.cxx index 911d814285e2..0f58b708b2ba 100644 --- a/svx/source/fmcomp/gridcell.cxx +++ b/svx/source/fmcomp/gridcell.cxx @@ -131,8 +131,7 @@ namespace } catch( const Exception& ) { - DBG_UNHANDLED_EXCEPTION("svx"); - OSL_FAIL( "getModelLineEndSetting: caught an exception!" ); + TOOLS_WARN_EXCEPTION( "svx", "getModelLineEndSetting" ); } return eFormat; } @@ -579,8 +578,7 @@ DbCellControl::DbCellControl( DbGridColumn& _rColumn ) } catch( const Exception& ) { - DBG_UNHANDLED_EXCEPTION("svx"); - OSL_FAIL( "DbCellControl::doPropertyListening: caught an exception!" ); + TOOLS_WARN_EXCEPTION( "svx", "DbCellControl::doPropertyListening" ); } } @@ -602,8 +600,7 @@ void DbCellControl::implDoPropertyListening(const OUString& _rPropertyName, bool } catch( const Exception& ) { - DBG_UNHANDLED_EXCEPTION("svx"); - OSL_FAIL( "DbCellControl::doPropertyListening: caught an exception!" ); + TOOLS_WARN_EXCEPTION( "svx", "DbCellControl::doPropertyListening" ); } } diff --git a/svx/source/form/fmcontrolbordermanager.cxx b/svx/source/form/fmcontrolbordermanager.cxx index d49af12c95a4..92da9708bd11 100644 --- a/svx/source/form/fmcontrolbordermanager.cxx +++ b/svx/source/form/fmcontrolbordermanager.cxx @@ -26,6 +26,7 @@ #include <com/sun/star/awt/XTextComponent.hpp> #include <com/sun/star/awt/XListBox.hpp> #include <tools/debug.hxx> +#include <tools/diagnose_ex.h> #include <osl/diagnose.h> @@ -240,7 +241,7 @@ namespace svxform } catch( const Exception& ) { - OSL_FAIL( "ControlBorderManager::controlStatusGained: caught an exception!" ); + TOOLS_WARN_EXCEPTION( "svx", "ControlBorderManager::controlStatusGained" ); } } @@ -264,7 +265,7 @@ namespace svxform } catch( const Exception& ) { - OSL_FAIL( "ControlBorderManager::controlStatusLost: caught an exception!" ); + TOOLS_WARN_EXCEPTION( "svx", "ControlBorderManager::controlStatusLost" ); } } @@ -413,7 +414,7 @@ namespace svxform } catch( const Exception& ) { - OSL_FAIL( "ControlBorderManager::validityChanged: caught an exception!" ); + TOOLS_WARN_EXCEPTION( "svx", "ControlBorderManager::validityChanged" ); } } diff --git a/svx/source/form/fmcontrollayout.cxx b/svx/source/form/fmcontrollayout.cxx index 999b482625f2..187fbf87d487 100644 --- a/svx/source/form/fmcontrollayout.cxx +++ b/svx/source/form/fmcontrollayout.cxx @@ -280,7 +280,7 @@ namespace svxform } catch( const Exception& ) { - OSL_FAIL( "ControlLayouter::initializeControlLayout: caught an exception!" ); + TOOLS_WARN_EXCEPTION( "svx", "ControlLayouter::initializeControlLayout" ); } } diff --git a/svx/source/form/fmdocumentclassification.cxx b/svx/source/form/fmdocumentclassification.cxx index 72974e70f0d8..b079a26f54bf 100644 --- a/svx/source/form/fmdocumentclassification.cxx +++ b/svx/source/form/fmdocumentclassification.cxx @@ -159,7 +159,7 @@ namespace svxform } catch( const Exception& ) { - OSL_FAIL( "DocumentClassification::classifyHostDocument: caught an exception!" ); + TOOLS_WARN_EXCEPTION( "svx", "DocumentClassification::classifyHostDocument" ); } return eType; diff --git a/svx/source/form/fmobjfac.cxx b/svx/source/form/fmobjfac.cxx index b698d43fd053..0fb1af632f87 100644 --- a/svx/source/form/fmobjfac.cxx +++ b/svx/source/form/fmobjfac.cxx @@ -99,8 +99,7 @@ namespace } catch( const Exception& ) { - DBG_UNHANDLED_EXCEPTION("svx"); - OSL_FAIL( "lcl_initProperty: caught an exception!" ); + TOOLS_WARN_EXCEPTION( "svx", "lcl_initProperty" ); } } } diff --git a/svx/source/form/fmpgeimp.cxx b/svx/source/form/fmpgeimp.cxx index 9146fe6605fd..1cc539c58144 100644 --- a/svx/source/form/fmpgeimp.cxx +++ b/svx/source/form/fmpgeimp.cxx @@ -583,7 +583,7 @@ Reference< XForm > FmFormPageImpl::findFormForDataSource( } catch(const Exception&) { - OSL_FAIL("FmFormPageImpl::findFormForDataSource: caught an exception!"); + TOOLS_WARN_EXCEPTION("svx", "FmFormPageImpl::findFormForDataSource"); } if (sLookupName == sFormDataSourceName) diff --git a/svx/source/form/fmshimp.cxx b/svx/source/form/fmshimp.cxx index dc436a2aec7c..845fbf030b85 100644 --- a/svx/source/form/fmshimp.cxx +++ b/svx/source/form/fmshimp.cxx @@ -1410,7 +1410,7 @@ void FmXFormShell::ExecuteTabOrderDialog_Lock(const Reference<XTabControllerMode } catch( const Exception& ) { - OSL_FAIL( "FmXFormShell::ExecuteTabOrderDialog: caught an exception!" ); + TOOLS_WARN_EXCEPTION( "svx", "FmXFormShell::ExecuteTabOrderDialog" ); } } diff --git a/svx/source/form/fmtextcontrolfeature.cxx b/svx/source/form/fmtextcontrolfeature.cxx index 9b7263408a7b..68bb8606a453 100644 --- a/svx/source/form/fmtextcontrolfeature.cxx +++ b/svx/source/form/fmtextcontrolfeature.cxx @@ -21,6 +21,7 @@ #include <fmtextcontrolshell.hxx> #include <osl/diagnose.h> +#include <tools/diagnose_ex.h> namespace svx { @@ -50,7 +51,7 @@ namespace svx } catch( const Exception& ) { - OSL_FAIL( "FmTextControlFeature::FmTextControlFeature: caught an exception!" ); + TOOLS_WARN_EXCEPTION( "svx", "FmTextControlFeature::FmTextControlFeature" ); } osl_atomic_decrement( &m_refCount ); } @@ -76,7 +77,7 @@ namespace svx } catch( const Exception& ) { - OSL_FAIL( "FmTextControlFeature::dispatch: caught an exception!" ); + TOOLS_WARN_EXCEPTION( "svx", "FmTextControlFeature::dispatch" ); } } @@ -106,7 +107,7 @@ namespace svx } catch( const Exception& ) { - OSL_FAIL( "FmTextControlFeature::dispose: caught an exception!" ); + TOOLS_WARN_EXCEPTION( "svx", "FmTextControlFeature::dispose" ); } } diff --git a/svx/source/form/fmtools.cxx b/svx/source/form/fmtools.cxx index 6297a3d0e69f..0e3dd230e5f9 100644 --- a/svx/source/form/fmtools.cxx +++ b/svx/source/form/fmtools.cxx @@ -75,6 +75,7 @@ #include <sfx2/bindings.hxx> #include <toolkit/helper/vclunohelper.hxx> #include <tools/debug.hxx> +#include <tools/diagnose_ex.h> #include <vcl/stdtext.hxx> #include <vcl/svapp.hxx> @@ -183,7 +184,7 @@ sal_Int32 getElementPos(const Reference< css::container::XIndexAccess>& xCont, c } catch(Exception&) { - OSL_FAIL( "getElementPos: caught an exception!" ); + TOOLS_WARN_EXCEPTION( "svx", "getElementPos" ); } } diff --git a/svx/source/form/fmundo.cxx b/svx/source/form/fmundo.cxx index d887bbad661f..de10047759c1 100644 --- a/svx/source/form/fmundo.cxx +++ b/svx/source/form/fmundo.cxx @@ -882,7 +882,7 @@ void FmXUndoEnvironment::switchListening( const Reference< XIndexContainer >& _r } catch( const Exception& ) { - OSL_FAIL( "FmXUndoEnvironment::switchListening: caught an exception!" ); + TOOLS_WARN_EXCEPTION( "svx", "FmXUndoEnvironment::switchListening" ); } } @@ -916,7 +916,7 @@ void FmXUndoEnvironment::switchListening( const Reference< XInterface >& _rxObje } catch( const Exception& ) { - OSL_FAIL( "FmXUndoEnvironment::switchListening: caught an exception!" ); + TOOLS_WARN_EXCEPTION( "svx", "FmXUndoEnvironment::switchListening" ); } } @@ -992,7 +992,7 @@ void FmUndoPropertyAction::Undo() } catch( const Exception& ) { - OSL_FAIL( "FmUndoPropertyAction::Undo: caught an exception!" ); + TOOLS_WARN_EXCEPTION( "svx", "FmUndoPropertyAction::Undo" ); } rEnv.UnLock(); } @@ -1012,7 +1012,7 @@ void FmUndoPropertyAction::Redo() } catch( const Exception& ) { - OSL_FAIL( "FmUndoPropertyAction::Redo: caught an exception!" ); + TOOLS_WARN_EXCEPTION( "svx", "FmUndoPropertyAction::Redo" ); } rEnv.UnLock(); } @@ -1162,7 +1162,7 @@ void FmUndoContainerAction::Undo() } catch( const Exception& ) { - OSL_FAIL( "FmUndoContainerAction::Undo: caught an exception!" ); + TOOLS_WARN_EXCEPTION( "svx", "FmUndoContainerAction::Undo" ); } rEnv.UnLock(); } @@ -1190,7 +1190,7 @@ void FmUndoContainerAction::Redo() } catch( const Exception& ) { - OSL_FAIL( "FmUndoContainerAction::Redo: caught an exception!" ); + TOOLS_WARN_EXCEPTION( "svx", "FmUndoContainerAction::Redo" ); } rEnv.UnLock(); } diff --git a/svx/source/form/formcontrolfactory.cxx b/svx/source/form/formcontrolfactory.cxx index 32b5d31fb232..02a41bc866aa 100644 --- a/svx/source/form/formcontrolfactory.cxx +++ b/svx/source/form/formcontrolfactory.cxx @@ -214,7 +214,7 @@ namespace svxform } catch( const Exception& ) { - OSL_FAIL( "lcl_getDataSourceIndirectProperties: caught an exception!" ); + TOOLS_WARN_EXCEPTION( "svx", "lcl_getDataSourceIndirectProperties" ); } return aInfo; } diff --git a/svx/source/form/formfeaturedispatcher.cxx b/svx/source/form/formfeaturedispatcher.cxx index 50faf597c463..33071378326c 100644 --- a/svx/source/form/formfeaturedispatcher.cxx +++ b/svx/source/form/formfeaturedispatcher.cxx @@ -91,7 +91,7 @@ namespace svx } catch( const Exception& ) { - OSL_FAIL( "OSingleFeatureDispatcher::notifyStatus: caught an exception!" ); + TOOLS_WARN_EXCEPTION( "svx", "OSingleFeatureDispatcher::notifyStatus" ); } } else diff --git a/svx/source/form/formtoolbars.cxx b/svx/source/form/formtoolbars.cxx index 52ee51101681..d46e7cc1b343 100644 --- a/svx/source/form/formtoolbars.cxx +++ b/svx/source/form/formtoolbars.cxx @@ -21,6 +21,7 @@ #include <com/sun/star/beans/XPropertySet.hpp> #include <osl/diagnose.h> +#include <tools/diagnose_ex.h> #include <svx/svxids.hrc> @@ -65,7 +66,7 @@ namespace svxform } catch( const Exception& ) { - OSL_FAIL( "FormToolboxes::toggleToolbox: caught an exception!" ); + TOOLS_WARN_EXCEPTION( "svx", "FormToolboxes::toggleToolbox" ); } } diff --git a/svx/source/form/navigatortree.cxx b/svx/source/form/navigatortree.cxx index 6950633e383b..9c1dc3ca3dd3 100644 --- a/svx/source/form/navigatortree.cxx +++ b/svx/source/form/navigatortree.cxx @@ -52,6 +52,7 @@ #include <svx/svxdlg.hxx> #include <svx/strings.hrc> +#include <tools/diagnose_ex.h> #include <bitmaps.hlst> #include <vcl/treelistentry.hxx> #include <vcl/commandevent.hxx> @@ -1191,7 +1192,7 @@ namespace svxform } catch( const Exception& ) { - OSL_FAIL( "NavigatorTree::doPaste: caught an exception!" ); + TOOLS_WARN_EXCEPTION( "svx", "NavigatorTree::doPaste" ); } } diff --git a/svx/source/form/tabwin.cxx b/svx/source/form/tabwin.cxx index b9caf389bd1f..25337d76c980 100644 --- a/svx/source/form/tabwin.cxx +++ b/svx/source/form/tabwin.cxx @@ -49,6 +49,7 @@ #include <comphelper/property.hxx> #include <sfx2/frame.hxx> #include <svx/dataaccessdescriptor.hxx> +#include <tools/diagnose_ex.h> #include <vcl/svapp.hxx> #include <tabwin.hrc> @@ -288,7 +289,7 @@ void FmFieldWin::UpdateContent(const css::uno::Reference< css::form::XForm > & x } catch( const Exception& ) { - OSL_FAIL( "FmTabWin::UpdateContent: caught an exception!" ); + TOOLS_WARN_EXCEPTION( "svx", "FmTabWin::UpdateContent" ); } } diff --git a/svx/source/svdraw/svdouno.cxx b/svx/source/svdraw/svdouno.cxx index 37c6ccd94477..7e5e6e571d6e 100644 --- a/svx/source/svdraw/svdouno.cxx +++ b/svx/source/svdraw/svdouno.cxx @@ -195,7 +195,7 @@ SdrUnoObj::~SdrUnoObj() } catch( const uno::Exception& ) { - OSL_FAIL( "SdrUnoObj::~SdrUnoObj: caught an exception!" ); + TOOLS_WARN_EXCEPTION( "svx", "SdrUnoObj::~SdrUnoObj" ); } } diff --git a/svx/source/tbxctrls/tbxcolor.cxx b/svx/source/tbxctrls/tbxcolor.cxx index 3a17e38820a4..f434c4334a9e 100644 --- a/svx/source/tbxctrls/tbxcolor.cxx +++ b/svx/source/tbxctrls/tbxcolor.cxx @@ -79,7 +79,7 @@ namespace svx } catch( const Exception& ) { - OSL_FAIL( "ToolboxAccess::toggleToolbox: caught an exception!" ); + TOOLS_WARN_EXCEPTION( "svx", "ToolboxAccess::toggleToolbox" ); } } |