sw/source/core/unocore/unofield.cxx | 12 +++++++++--- 1 file changed, 9 insertions(+), 3 deletions(-)
New commits: commit c409b66842bd8eb368f9e6be4abb17dee3070682 Author: Stephan Bergmann <sberg...@redhat.com> Date: Fri Nov 22 09:03:38 2013 +0100 Improve exception messages Change-Id: I95b8d1bfcba66ba5670345e9159f0dca11e6d967 diff --git a/sw/source/core/unocore/unofield.cxx b/sw/source/core/unocore/unofield.cxx index d2b91b9..96ba067 100644 --- a/sw/source/core/unocore/unofield.cxx +++ b/sw/source/core/unocore/unofield.cxx @@ -2643,12 +2643,16 @@ uno::Any SwXTextFieldMasters::getByName(const OUString& rName) OUString sName(rName), sTypeName; sal_uInt16 nResId = lcl_GetIdByName( sName, sTypeName ); if( USHRT_MAX == nResId ) - throw container::NoSuchElementException(); + throw container::NoSuchElementException( + "SwXTextFieldMasters::getByName(" + rName + ")", + css::uno::Reference<css::uno::XInterface>()); sName = sName.copy(std::min(sTypeName.getLength()+1, sName.getLength())); SwFieldType* pType = GetDoc()->GetFldType(nResId, sName, sal_True); if(!pType) - throw container::NoSuchElementException(); + throw container::NoSuchElementException( + "SwXTextFieldMasters::getByName(" + rName + ")", + css::uno::Reference<css::uno::XInterface>()); uno::Reference<beans::XPropertySet> const xRet( SwXFieldMaster::CreateXFieldMaster(*GetDoc(), *pType)); @@ -2978,7 +2982,9 @@ throw (container::NoSuchElementException, lang::WrappedTargetException, SolarMutexGuard aGuard; if (!(m_pImpl->m_nNextIndex < m_pImpl->m_Items.getLength())) - throw container::NoSuchElementException(); + throw container::NoSuchElementException( + "SwXFieldEnumeration::nextElement", + css::uno::Reference<css::uno::XInterface>()); #if OSL_DEBUG_LEVEL > 1 uno::Reference< text::XTextField > *pItems = m_pImpl->m_Items.getArray(); _______________________________________________ Libreoffice-commits mailing list libreoffice-comm...@lists.freedesktop.org http://lists.freedesktop.org/mailman/listinfo/libreoffice-commits