diff options
68 files changed, 214 insertions, 214 deletions
diff --git a/UnoControls/source/base/multiplexer.cxx b/UnoControls/source/base/multiplexer.cxx index 27ef124b5e41..c900d0276b04 100644 --- a/UnoControls/source/base/multiplexer.cxx +++ b/UnoControls/source/base/multiplexer.cxx @@ -489,7 +489,7 @@ void OMRCListenerMultiplexerHelper::impl_adviseToPeer( const Reference< XWind } else { - OSL_ENSURE( sal_False, "unknown listener" ); + OSL_FAIL( "unknown listener" ); } } @@ -521,7 +521,7 @@ void OMRCListenerMultiplexerHelper::impl_unadviseFromPeer( const Reference< X } else { - OSL_ENSURE( sal_False, "unknown listener" ); + OSL_FAIL( "unknown listener" ); } } diff --git a/accessibility/source/standard/vclxaccessibleedit.cxx b/accessibility/source/standard/vclxaccessibleedit.cxx index bbd329594f24..d8da35278927 100644 --- a/accessibility/source/standard/vclxaccessibleedit.cxx +++ b/accessibility/source/standard/vclxaccessibleedit.cxx @@ -619,7 +619,7 @@ sal_Bool VCLXAccessibleEdit::setText( const ::rtl::OUString& sText ) throw (Runt } catch( const IndexOutOfBoundsException& ) { - OSL_ENSURE( sal_False, "VCLXAccessibleText::setText: caught an exception!" ); + OSL_FAIL( "VCLXAccessibleText::setText: caught an exception!" ); } return bSuccess; } diff --git a/basctl/source/accessibility/accessibledialogcontrolshape.cxx b/basctl/source/accessibility/accessibledialogcontrolshape.cxx index 416762f04b61..8c7fdcfa324e 100644 --- a/basctl/source/accessibility/accessibledialogcontrolshape.cxx +++ b/basctl/source/accessibility/accessibledialogcontrolshape.cxx @@ -221,7 +221,7 @@ Window* AccessibleDialogControlShape::GetWindow() const } catch ( const Exception& ) { - OSL_ENSURE( sal_False, "AccessibleDialogControlShape::GetModelStringProperty: caught an exception!" ); + OSL_FAIL( "AccessibleDialogControlShape::GetModelStringProperty: caught an exception!" ); } return sReturn; diff --git a/cui/source/dialogs/multifil.cxx b/cui/source/dialogs/multifil.cxx index bdae49e60979..cc76430f7da0 100644 --- a/cui/source/dialogs/multifil.cxx +++ b/cui/source/dialogs/multifil.cxx @@ -121,7 +121,7 @@ IMPL_LINK( SvxMultiFileDialog, AddHdl_Impl, PushButton *, pBtn ) } // end of try(} catch( const Exception& ) // catch every exception of comparison { - OSL_ENSURE( sal_False, "AddHdl_Impl: caught an unexpected exception!" ); + OSL_FAIL( "AddHdl_Impl: caught an unexpected exception!" ); } if ( bDuplicated ) // #97807# -------------------- diff --git a/cui/source/options/connpooloptions.cxx b/cui/source/options/connpooloptions.cxx index 988d8574c75a..158652898b43 100644 --- a/cui/source/options/connpooloptions.cxx +++ b/cui/source/options/connpooloptions.cxx @@ -237,7 +237,7 @@ namespace offapp sReturn = String::CreateFromInt32(_rPos->nTimeoutSeconds); break; default: - OSL_ENSURE(sal_False, "DriverListControl::implGetCellText: invalid column id!"); + OSL_FAIL("DriverListControl::implGetCellText: invalid column id!"); } return sReturn; } @@ -256,7 +256,7 @@ namespace offapp String sReturn; if (nRow > m_aSettings.size()) { - OSL_ENSURE(sal_False, "DriverListControl::GetCellText: don't ask me for such rows!"); + OSL_FAIL("DriverListControl::GetCellText: don't ask me for such rows!"); } else { @@ -376,7 +376,7 @@ namespace offapp m_pDriverList->Update(pDriverSettings->getSettings()); else { - OSL_ENSURE(sal_False, "ConnectionPoolOptionsPage::implInitControls: missing the DriverTimeouts item!"); + OSL_FAIL("ConnectionPoolOptionsPage::implInitControls: missing the DriverTimeouts item!"); m_pDriverList->Update(DriverPoolingSettings()); } m_pDriverList->saveValue(); diff --git a/cui/source/options/optgdlg.cxx b/cui/source/options/optgdlg.cxx index 28d426e6e79b..03f35d6d1111 100644 --- a/cui/source/options/optgdlg.cxx +++ b/cui/source/options/optgdlg.cxx @@ -1344,7 +1344,7 @@ OfaLanguagesTabPage::OfaLanguagesTabPage( Window* pParent, const SfxItemSet& rSe // we'll just leave the box in it's default setting and won't // even give it event handler... OString aMsg = OUStringToOString(e.Message, RTL_TEXTENCODING_ASCII_US); - OSL_ENSURE(sal_False, aMsg.getStr()); + OSL_FAIL(aMsg.getStr()); } aWesternLanguageLB.SetLanguageList( LANG_LIST_WESTERN | LANG_LIST_ONLY_KNOWN, sal_True, sal_False, sal_True ); @@ -1500,7 +1500,7 @@ sal_Bool OfaLanguagesTabPage::FillItemSet( SfxItemSet& rSet ) theConfigProvider->createInstanceWithArguments(sAccessUpdSrvc, theArgs ), UNO_QUERY_THROW ); if ( !m_sUserLocaleValue.equals(aLangString)) { - // OSL_ENSURE(sal_False, "UserInterface language was changed, restart."); + // OSL_FAIL("UserInterface language was changed, restart."); // write new value xProp->setPropertyValue(sUserLocaleKey, makeAny(aLangString)); Reference< XChangesBatch >(xProp, UNO_QUERY_THROW)->commitChanges(); @@ -1527,7 +1527,7 @@ sal_Bool OfaLanguagesTabPage::FillItemSet( SfxItemSet& rSet ) // we'll just leave the box in it's default setting and won't // even give it event handler... OString aMsg = OUStringToOString(e.Message, RTL_TEXTENCODING_ASCII_US); - OSL_ENSURE(sal_False, aMsg.getStr()); + OSL_FAIL(aMsg.getStr()); } OUString sLang = pLangConfig->aSysLocaleOptions.GetLocaleConfigString(); diff --git a/cui/source/options/optpath.cxx b/cui/source/options/optpath.cxx index a3a30c1e13db..45119573c5da 100644 --- a/cui/source/options/optpath.cxx +++ b/cui/source/options/optpath.cxx @@ -799,7 +799,7 @@ void SvxPathTabPage::GetPathList( } catch( const Exception& ) { - OSL_ENSURE( sal_False, "SvxPathTabPage::GetPathList(): caught an exception!" ); + OSL_FAIL( "SvxPathTabPage::GetPathList(): caught an exception!" ); } } @@ -844,7 +844,7 @@ void SvxPathTabPage::SetPathList( } catch( const Exception& ) { - OSL_ENSURE( sal_False, "SvxPathTabPage::SetPathList(): caught an exception!" ); + OSL_FAIL( "SvxPathTabPage::SetPathList(): caught an exception!" ); } } diff --git a/cui/source/options/sdbcdriverenum.cxx b/cui/source/options/sdbcdriverenum.cxx index 86e4ec494426..98b7bced375a 100644 --- a/cui/source/options/sdbcdriverenum.cxx +++ b/cui/source/options/sdbcdriverenum.cxx @@ -84,7 +84,7 @@ namespace offapp } catch(const Exception&) { - OSL_ENSURE(sal_False, "ODriverEnumerationImpl::ODriverEnumerationImpl: caught an exception while enumerating the drivers!"); + OSL_FAIL("ODriverEnumerationImpl::ODriverEnumerationImpl: caught an exception while enumerating the drivers!"); } } diff --git a/embedserv/source/embed/docholder.cxx b/embedserv/source/embed/docholder.cxx index 3bafde9e67ae..e513b4b38b48 100644 --- a/embedserv/source/embed/docholder.cxx +++ b/embedserv/source/embed/docholder.cxx @@ -945,7 +945,7 @@ void DocumentHolder::show() } catch( uno::Exception& ) { - OSL_ENSURE( sal_False, "Can not show the frame!\n" ); + OSL_FAIL( "Can not show the frame!\n" ); } } diff --git a/extensions/source/plugin/base/multiplx.cxx b/extensions/source/plugin/base/multiplx.cxx index 209885f6a475..5f7f6a26719f 100644 --- a/extensions/source/plugin/base/multiplx.cxx +++ b/extensions/source/plugin/base/multiplx.cxx @@ -107,7 +107,7 @@ void MRCListenerMultiplexerHelper::adviseToPeer( const Reference< ::com::sun::st } else { - OSL_ENSURE( sal_False, "unknown listener" ); + OSL_FAIL( "unknown listener" ); } } @@ -135,7 +135,7 @@ void MRCListenerMultiplexerHelper::unadviseFromPeer( const Reference< ::com::sun } else { - OSL_ENSURE( sal_False, "unknown listener" ); + OSL_FAIL( "unknown listener" ); } } diff --git a/extensions/source/propctrlr/buttonnavigationhandler.cxx b/extensions/source/propctrlr/buttonnavigationhandler.cxx index db097ce89cfb..914ba8163870 100644 --- a/extensions/source/propctrlr/buttonnavigationhandler.cxx +++ b/extensions/source/propctrlr/buttonnavigationhandler.cxx @@ -181,7 +181,7 @@ namespace pcr break; default: - OSL_ENSURE( sal_False, "ButtonNavigationHandler::setPropertyValue: cannot handle this id!" ); + OSL_FAIL( "ButtonNavigationHandler::setPropertyValue: cannot handle this id!" ); } } @@ -265,7 +265,7 @@ namespace pcr break; default: - OSL_ENSURE( sal_False, "ButtonNavigationHandler::actuatingPropertyChanged: cannot handle this id!" ); + OSL_FAIL( "ButtonNavigationHandler::actuatingPropertyChanged: cannot handle this id!" ); } } diff --git a/extensions/source/propctrlr/cellbindinghandler.cxx b/extensions/source/propctrlr/cellbindinghandler.cxx index aa293ce11d0a..23b061844a8c 100644 --- a/extensions/source/propctrlr/cellbindinghandler.cxx +++ b/extensions/source/propctrlr/cellbindinghandler.cxx @@ -185,7 +185,7 @@ namespace pcr } catch( const Exception& ) { - OSL_ENSURE( sal_False, "OPropertyBrowserController::actuatingPropertyChanged( ListCellRange ): caught an exception while resetting the string items!" ); + OSL_FAIL( "OPropertyBrowserController::actuatingPropertyChanged( ListCellRange ): caught an exception while resetting the string items!" ); } } } @@ -238,7 +238,7 @@ namespace pcr } catch( const Exception& ) { - OSL_ENSURE( sal_False, "CellBindingPropertyHandler::impl_updateDependentProperty_nothrow: caught an exception!" ); + OSL_FAIL( "CellBindingPropertyHandler::impl_updateDependentProperty_nothrow: caught an exception!" ); } } @@ -356,7 +356,7 @@ namespace pcr } catch( const Exception& ) { - OSL_ENSURE( sal_False, "CellBindingPropertyHandler::setPropertyValue: caught an exception!" ); + OSL_FAIL( "CellBindingPropertyHandler::setPropertyValue: caught an exception!" ); } } diff --git a/extensions/source/propctrlr/cellbindinghelper.cxx b/extensions/source/propctrlr/cellbindinghelper.cxx index 24fdc7fc28c3..8c42d311e162 100644 --- a/extensions/source/propctrlr/cellbindinghelper.cxx +++ b/extensions/source/propctrlr/cellbindinghelper.cxx @@ -198,7 +198,7 @@ namespace pcr } catch( const Exception& ) { - OSL_ENSURE( sal_False, "CellBindingHelper::doConvertAddressRepresentations: caught an exception!" ); + OSL_FAIL( "CellBindingHelper::doConvertAddressRepresentations: caught an exception!" ); } } @@ -297,7 +297,7 @@ namespace pcr } catch ( const Exception& ) { - OSL_ENSURE( sal_False, "CellBindingHelper::createDocumentDependentInstance: could not create the binding at the document!" ); + OSL_FAIL( "CellBindingHelper::createDocumentDependentInstance: could not create the binding at the document!" ); } } return xReturn; @@ -326,7 +326,7 @@ namespace pcr } catch( const Exception& ) { - OSL_ENSURE( sal_False, "CellBindingHelper::getAddressFromCellBinding: caught an exception!" ); + OSL_FAIL( "CellBindingHelper::getAddressFromCellBinding: caught an exception!" ); } return bReturn; @@ -376,7 +376,7 @@ namespace pcr } catch( const Exception& ) { - OSL_ENSURE( sal_False, "CellBindingHelper::getStringAddressFromCellListSource: caught an exception!" ); + OSL_FAIL( "CellBindingHelper::getStringAddressFromCellListSource: caught an exception!" ); } return sAddress; @@ -452,7 +452,7 @@ namespace pcr } catch( const Exception& ) { - OSL_ENSURE( sal_False, "CellBindingHelper::isCellIntegerBindingAllowed: caught an exception!" ); + OSL_FAIL( "CellBindingHelper::isCellIntegerBindingAllowed: caught an exception!" ); // are there really control models which survive isCellBindingAllowed, but don't have a ClassId // property? bAllow = false; @@ -489,7 +489,7 @@ namespace pcr } catch( const Exception& ) { - OSL_ENSURE( sal_False, "CellBindingHelper::isCellBindingAllowed: caught an exception!" ); + OSL_FAIL( "CellBindingHelper::isCellBindingAllowed: caught an exception!" ); bAllow = false; } } diff --git a/extensions/source/propctrlr/editpropertyhandler.cxx b/extensions/source/propctrlr/editpropertyhandler.cxx index cb5aac0137b6..b00b1ceafb55 100644 --- a/extensions/source/propctrlr/editpropertyhandler.cxx +++ b/extensions/source/propctrlr/editpropertyhandler.cxx @@ -140,7 +140,7 @@ namespace pcr } catch( const Exception& ) { - OSL_ENSURE( sal_False, "EditPropertyHandler::getPropertyValue: caught an exception!" ); + OSL_FAIL( "EditPropertyHandler::getPropertyValue: caught an exception!" ); } return aReturn; @@ -181,7 +181,7 @@ namespace pcr case TEXTTYPE_MULTILINE: bMultiLine = sal_True; bRichText = sal_False; break; case TEXTTYPE_RICHTEXT: bMultiLine = sal_True; bRichText = sal_True; break; default: - OSL_ENSURE( sal_False, "EditPropertyHandler::setPropertyValue: invalid text type!" ); + OSL_FAIL( "EditPropertyHandler::setPropertyValue: invalid text type!" ); } m_xComponent->setPropertyValue( PROPERTY_MULTILINE, makeAny( bMultiLine ) ); @@ -190,12 +190,12 @@ namespace pcr break; default: - OSL_ENSURE( sal_False, "EditPropertyHandler::setPropertyValue: cannot handle this id!" ); + OSL_FAIL( "EditPropertyHandler::setPropertyValue: cannot handle this id!" ); } } catch( const Exception& ) { - OSL_ENSURE( sal_False, "EditPropertyHandler::setPropertyValue: caught an exception!" ); + OSL_FAIL( "EditPropertyHandler::setPropertyValue: caught an exception!" ); } } @@ -314,7 +314,7 @@ namespace pcr break; default: - OSL_ENSURE( sal_False, "EditPropertyHandler::actuatingPropertyChanged: cannot handle this id!" ); + OSL_FAIL( "EditPropertyHandler::actuatingPropertyChanged: cannot handle this id!" ); } } diff --git a/extensions/source/propctrlr/eformshelper.cxx b/extensions/source/propctrlr/eformshelper.cxx index 0d1120658d86..54f78e55a013 100644 --- a/extensions/source/propctrlr/eformshelper.cxx +++ b/extensions/source/propctrlr/eformshelper.cxx @@ -109,7 +109,7 @@ namespace pcr } catch( const Exception& ) { - OSL_ENSURE( sal_False, "EFormsHelper::isEForm: caught an exception!" ); + OSL_FAIL( "EFormsHelper::isEForm: caught an exception!" ); } return false; } @@ -202,7 +202,7 @@ namespace pcr } catch( const Exception& ) { - OSL_ENSURE( sal_False, "EFormsHelper::canBindToDataType: caught an exception!" ); + OSL_FAIL( "EFormsHelper::canBindToDataType: caught an exception!" ); } return bCan; @@ -219,7 +219,7 @@ namespace pcr } catch( const Exception& ) { - OSL_ENSURE( sal_False, "EFormsHelper::isListEntrySink: caught an exception!" ); + OSL_FAIL( "EFormsHelper::isListEntrySink: caught an exception!" ); } return bIs; } @@ -328,7 +328,7 @@ namespace pcr } catch( const Exception& ) { - OSL_ENSURE( sal_False, "EFormsHelper::getFormModelNames: caught an exception!" ); + OSL_FAIL( "EFormsHelper::getFormModelNames: caught an exception!" ); } } } @@ -354,7 +354,7 @@ namespace pcr } catch( const Exception& ) { - OSL_ENSURE( sal_False, "EFormsHelper::getBindingNames: caught an exception!" ); + OSL_FAIL( "EFormsHelper::getBindingNames: caught an exception!" ); } } @@ -371,7 +371,7 @@ namespace pcr } catch( const Exception& ) { - OSL_ENSURE( sal_False, "EFormsHelper::getFormModelByName: caught an exception!" ); + OSL_FAIL( "EFormsHelper::getFormModelByName: caught an exception!" ); } return xReturn; } @@ -390,7 +390,7 @@ namespace pcr } catch( const Exception& ) { - OSL_ENSURE( sal_False, "EFormsHelper::getCurrentFormModel: caught an exception!" ); + OSL_FAIL( "EFormsHelper::getCurrentFormModel: caught an exception!" ); } return xModel; } @@ -407,7 +407,7 @@ namespace pcr } catch( const Exception& ) { - OSL_ENSURE( sal_False, "EFormsHelper::getCurrentFormModel: caught an exception!" ); + OSL_FAIL( "EFormsHelper::getCurrentFormModel: caught an exception!" ); } return sModelName; } @@ -424,7 +424,7 @@ namespace pcr } catch( const Exception& ) { - OSL_ENSURE( sal_False, "EFormsHelper::getCurrentBinding: caught an exception!" ); + OSL_FAIL( "EFormsHelper::getCurrentBinding: caught an exception!" ); } return xBinding; @@ -442,7 +442,7 @@ namespace pcr } catch( const Exception& ) { - OSL_ENSURE( sal_False, "EFormsHelper::getCurrentBindingName: caught an exception!" ); + OSL_FAIL( "EFormsHelper::getCurrentBindingName: caught an exception!" ); } return sBindingName; } @@ -460,7 +460,7 @@ namespace pcr } catch( const Exception& ) { - OSL_ENSURE( sal_False, "EFormsHelper::getCurrentListSourceBinding: caught an exception!" ); + OSL_FAIL( "EFormsHelper::getCurrentListSourceBinding: caught an exception!" ); } return xReturn; } @@ -477,7 +477,7 @@ namespace pcr } catch( const Exception& ) { - OSL_ENSURE( sal_False, "EFormsHelper::setListSourceBinding: caught an exception!" ); + OSL_FAIL( "EFormsHelper::setListSourceBinding: caught an exception!" ); } } @@ -503,7 +503,7 @@ namespace pcr } catch( const Exception& ) { - OSL_ENSURE( sal_False, "EFormsHelper::setBinding: caught an exception!" ); + OSL_FAIL( "EFormsHelper::setBinding: caught an exception!" ); } } @@ -637,7 +637,7 @@ namespace pcr } catch( const Exception& ) { - OSL_ENSURE( sal_False, "EFormsHelper::getModelElementUIName: caught an exception!" ); + OSL_FAIL( "EFormsHelper::getModelElementUIName: caught an exception!" ); } return sUIName; @@ -712,7 +712,7 @@ namespace pcr } catch( const Exception& ) { - OSL_ENSURE( sal_False, "EFormsHelper::getAllElementUINames: caught an exception!" ); + OSL_FAIL( "EFormsHelper::getAllElementUINames: caught an exception!" ); } _rElementNames.resize( rMapUINameToElement.size() ); @@ -741,7 +741,7 @@ namespace pcr } catch( const Exception& ) { - OSL_ENSURE( sal_False, "EFormsHelper::firePropertyChange: caught an exception!" ); + OSL_FAIL( "EFormsHelper::firePropertyChange: caught an exception!" ); } } @@ -778,7 +778,7 @@ namespace pcr } catch( const Exception& ) { - OSL_ENSURE( sal_False, "EFormsHelper::firePropertyChanges: caught an exception!" ); + OSL_FAIL( "EFormsHelper::firePropertyChanges: caught an exception!" ); } } diff --git a/extensions/source/propctrlr/eformspropertyhandler.cxx b/extensions/source/propctrlr/eformspropertyhandler.cxx index 72fdca1ab2e0..99db682d4ac1 100644 --- a/extensions/source/propctrlr/eformspropertyhandler.cxx +++ b/extensions/source/propctrlr/eformspropertyhandler.cxx @@ -164,7 +164,7 @@ namespace pcr sMessage += "\n(have been asked for the \""; sMessage += ::rtl::OString( _rPropertyName.getStr(), _rPropertyName.getLength(), RTL_TEXTENCODING_ASCII_US ); sMessage += "\" property.)"; - OSL_ENSURE( sal_False, sMessage.getStr() ); + OSL_FAIL( sMessage.getStr() ); #endif } return aReturn; @@ -280,7 +280,7 @@ namespace pcr } catch( const Exception& ) { - OSL_ENSURE( sal_False, "EFormsPropertyHandler::setPropertyValue: caught an exception!" ); + OSL_FAIL( "EFormsPropertyHandler::setPropertyValue: caught an exception!" ); } } @@ -538,7 +538,7 @@ namespace pcr } catch( const Exception& ) { - OSL_ENSURE( sal_False, "EFormsPropertyHandler::onInteractivePropertySelection: caught an exception!" ); + OSL_FAIL( "EFormsPropertyHandler::onInteractivePropertySelection: caught an exception!" ); } // something went wrong here ...(but has been asserted already) diff --git a/extensions/source/propctrlr/formcomponenthandler.cxx b/extensions/source/propctrlr/formcomponenthandler.cxx index b676176bf375..e865f99b6431 100644 --- a/extensions/source/propctrlr/formcomponenthandler.cxx +++ b/extensions/source/propctrlr/formcomponenthandler.cxx @@ -2022,7 +2022,7 @@ namespace pcr } catch( const Exception& ) { - OSL_ENSURE( sal_False, "FormComponentPropertyHandler::impl_updateDependentProperty_nothrow: caught an exception!" ); + OSL_FAIL( "FormComponentPropertyHandler::impl_updateDependentProperty_nothrow: caught an exception!" ); } } @@ -2096,7 +2096,7 @@ namespace pcr } catch( const Exception& ) { - OSL_ENSURE( sal_False, "FormComponentPropertyHandler::impl_initComponentMetaData_throw: caught an exception!" ); + OSL_FAIL( "FormComponentPropertyHandler::impl_initComponentMetaData_throw: caught an exception!" ); } } @@ -2350,7 +2350,7 @@ namespace pcr } catch( const Exception& ) { - OSL_ENSURE( sal_False, "FormComponentPropertyHandler::impl_getRowSet_nothrow: caught an exception!" ); + OSL_FAIL( "FormComponentPropertyHandler::impl_getRowSet_nothrow: caught an exception!" ); } return xReturn; } @@ -2678,7 +2678,7 @@ namespace pcr catch (SQLException& e) { aErrorInfo = e; } catch( const Exception& ) { - OSL_ENSURE( sal_False, "FormComponentPropertyHandler::impl_dialogFilterOrSort_nothrow: caught an exception!" ); + OSL_FAIL( "FormComponentPropertyHandler::impl_dialogFilterOrSort_nothrow: caught an exception!" ); } if ( aErrorInfo.isValid() ) @@ -2770,7 +2770,7 @@ namespace pcr } catch( const Exception& ) { - OSL_ENSURE( sal_False, "FormComponentPropertyHandler::impl_dialogFormatting_nothrow: : caught an exception!" ); + OSL_FAIL( "FormComponentPropertyHandler::impl_dialogFormatting_nothrow: : caught an exception!" ); } return bChanged; } diff --git a/extensions/source/propctrlr/formlinkdialog.cxx b/extensions/source/propctrlr/formlinkdialog.cxx index 725706febe98..dbec1862d10f 100644 --- a/extensions/source/propctrlr/formlinkdialog.cxx +++ b/extensions/source/propctrlr/formlinkdialog.cxx @@ -239,7 +239,7 @@ namespace pcr } catch( const Exception& ) { - OSL_ENSURE( sal_False, "FormLinkDialog::commitLinkPairs: caught an exception while setting the properties!" ); + OSL_FAIL( "FormLinkDialog::commitLinkPairs: caught an exception while setting the properties!" ); } } @@ -343,7 +343,7 @@ namespace pcr } catch( const Exception& ) { - OSL_ENSURE( sal_False, "FormLinkDialog::initializeLinks: caught an exception!" ); + OSL_FAIL( "FormLinkDialog::initializeLinks: caught an exception!" ); } } @@ -394,7 +394,7 @@ namespace pcr } catch( const Exception& ) { - OSL_ENSURE( sal_False, "FormLinkDialog::getFormDataSourceType: caught an exception!" ); + OSL_FAIL( "FormLinkDialog::getFormDataSourceType: caught an exception!" ); } return sReturn; } @@ -433,7 +433,7 @@ namespace pcr catch (const SQLException& e ) { aErrorInfo = e; } catch( const Exception& ) { - OSL_ENSURE( sal_False, "FormLinkDialog::getFormFields: caught a non-SQL exception!" ); + OSL_FAIL( "FormLinkDialog::getFormFields: caught a non-SQL exception!" ); } if ( aErrorInfo.isValid() ) @@ -500,7 +500,7 @@ namespace pcr } catch( const Exception& ) { - OSL_ENSURE( sal_False, "FormLinkDialog::getCanonicUnderlyingTable: caught an exception!" ); + OSL_FAIL( "FormLinkDialog::getCanonicUnderlyingTable: caught an exception!" ); } return xTable; } @@ -565,7 +565,7 @@ namespace pcr } catch( const Exception& ) { - OSL_ENSURE( sal_False, "FormLinkDialog::getExistingRelation: caught an exception!" ); + OSL_FAIL( "FormLinkDialog::getExistingRelation: caught an exception!" ); } return ( _rLeftFields.getLength() > 0 ) && ( _rLeftFields[ 0 ].getLength() > 0 ); @@ -641,7 +641,7 @@ namespace pcr } catch( const Exception& ) { - OSL_ENSURE( sal_False, "FormLinkDialog::initializeSuggest: caught an exception!" ); + OSL_FAIL( "FormLinkDialog::initializeSuggest: caught an exception!" ); } } diff --git a/extensions/source/propctrlr/formmetadata.cxx b/extensions/source/propctrlr/formmetadata.cxx index c13c7193d7d7..16dc70b05187 100644 --- a/extensions/source/propctrlr/formmetadata.cxx +++ b/extensions/source/propctrlr/formmetadata.cxx @@ -517,7 +517,7 @@ namespace pcr nStringItemsResId = RID_RSC_ENUM_SHEET_ANCHOR_TYPE; break; default: - OSL_ENSURE( sal_False, "OPropertyInfoService::getPropertyEnumRepresentations: unknown enum property!" ); + OSL_FAIL( "OPropertyInfoService::getPropertyEnumRepresentations: unknown enum property!" ); break; } diff --git a/extensions/source/propctrlr/genericpropertyhandler.cxx b/extensions/source/propctrlr/genericpropertyhandler.cxx index 3802e68dd039..df06374fe2d2 100644 --- a/extensions/source/propctrlr/genericpropertyhandler.cxx +++ b/extensions/source/propctrlr/genericpropertyhandler.cxx @@ -121,7 +121,7 @@ namespace pcr } catch( const Exception& ) { - OSL_ENSURE( sal_False, "EnumRepresentation::EnumRepresentation: caught an exception!" ); + OSL_FAIL( "EnumRepresentation::EnumRepresentation: caught an exception!" ); } } @@ -136,7 +136,7 @@ namespace pcr } catch( const Exception& ) { - OSL_ENSURE( sal_False, "EnumRepresentation::getDescriptions: caught an exception!" ); + OSL_FAIL( "EnumRepresentation::getDescriptions: caught an exception!" ); } return ::std::vector< ::rtl::OUString >( aNames.getConstArray(), aNames.getConstArray() + aNames.getLength() ); @@ -153,7 +153,7 @@ namespace pcr } catch( const Exception& ) { - OSL_ENSURE( sal_False, "EnumRepresentation::impl_getValues: caught an exception!" ); + OSL_FAIL( "EnumRepresentation::impl_getValues: caught an exception!" ); } } @@ -602,7 +602,7 @@ namespace pcr } catch( const Exception& ) { - OSL_ENSURE( sal_False, "GenericPropertyHandler::impl_ensurePropertyMap: caught an exception!" ); + OSL_FAIL( "GenericPropertyHandler::impl_ensurePropertyMap: caught an exception!" ); } } } diff --git a/extensions/source/propctrlr/handlerhelper.cxx b/extensions/source/propctrlr/handlerhelper.cxx index 65e5507deb34..e813e205267c 100644 --- a/extensions/source/propctrlr/handlerhelper.cxx +++ b/extensions/source/propctrlr/handlerhelper.cxx @@ -216,7 +216,7 @@ namespace pcr } catch( const Exception& ) { - OSL_ENSURE( sal_False, "PropertyHandlerHelper::convertToPropertyValue: caught an exception while converting via TypeConverter!" ); + OSL_FAIL( "PropertyHandlerHelper::convertToPropertyValue: caught an exception while converting via TypeConverter!" ); } } @@ -246,7 +246,7 @@ namespace pcr } catch( const Exception& ) { - OSL_ENSURE( sal_False, "PropertyHandlerHelper::convertToControlValue: caught an exception while converting via TypeConverter!" ); + OSL_FAIL( "PropertyHandlerHelper::convertToControlValue: caught an exception while converting via TypeConverter!" ); } } diff --git a/extensions/source/propctrlr/listselectiondlg.cxx b/extensions/source/propctrlr/listselectiondlg.cxx index 3bf379813739..774757ee3b34 100644 --- a/extensions/source/propctrlr/listselectiondlg.cxx +++ b/extensions/source/propctrlr/listselectiondlg.cxx @@ -110,7 +110,7 @@ namespace pcr } catch( const Exception& ) { - OSL_ENSURE( sal_False, "ListSelectionDialog::initialize: caught an exception!" ); + OSL_FAIL( "ListSelectionDialog::initialize: caught an exception!" ); } } @@ -129,7 +129,7 @@ namespace pcr } catch( const Exception& ) { - OSL_ENSURE( sal_False, "ListSelectionDialog::commitSelection: caught an exception!" ); + OSL_FAIL( "ListSelectionDialog::commitSelection: caught an exception!" ); } } diff --git a/extensions/source/propctrlr/pcrcomponentcontext.cxx b/extensions/source/propctrlr/pcrcomponentcontext.cxx index 70de26669887..dfb80d409e16 100644 --- a/extensions/source/propctrlr/pcrcomponentcontext.cxx +++ b/extensions/source/propctrlr/pcrcomponentcontext.cxx @@ -79,7 +79,7 @@ namespace pcr } catch( const Exception& ) { - OSL_ENSURE( sal_False, "PropertyHandler::getContextValueByName: caught an exception!" ); + OSL_FAIL( "PropertyHandler::getContextValueByName: caught an exception!" ); } return aReturn; } diff --git a/extensions/source/propctrlr/propcontroller.cxx b/extensions/source/propctrlr/propcontroller.cxx index 3c1da2b3b53b..dce1d0265fb7 100644 --- a/extensions/source/propctrlr/propcontroller.cxx +++ b/extensions/source/propctrlr/propcontroller.cxx @@ -401,7 +401,7 @@ namespace pcr } catch( const Exception& ) { - OSL_ENSURE( sal_False, "OPropertyBrowserController::attachFrame: caught an exception!" ); + OSL_FAIL( "OPropertyBrowserController::attachFrame: caught an exception!" ); } } @@ -470,7 +470,7 @@ namespace pcr } catch( const Exception& ) { - OSL_ENSURE( sal_False, "OPropertyBrowserController::suspendPropertyHandlers_nothrow: caught an exception!" ); + OSL_FAIL( "OPropertyBrowserController::suspendPropertyHandlers_nothrow: caught an exception!" ); } } return sal_True; @@ -1192,7 +1192,7 @@ namespace pcr } catch( const Exception& ) { - OSL_ENSURE( sal_False, "OPropertyBrowserController::describePropertyLine: caught an exception!" ); + OSL_FAIL( "OPropertyBrowserController::describePropertyLine: caught an exception!" ); } } @@ -1590,7 +1590,7 @@ namespace pcr } catch( const Exception& ) { - OSL_ENSURE( sal_False, "OPropertyBrowserController::rebuildPropertyUI: caught an exception!" ); + OSL_FAIL( "OPropertyBrowserController::rebuildPropertyUI: caught an exception!" ); } getPropertyBox().ChangeEntry( aDescriptor ); diff --git a/extensions/source/propctrlr/pushbuttonnavigation.cxx b/extensions/source/propctrlr/pushbuttonnavigation.cxx index 721d7d95c22d..ed546e700ae2 100644 --- a/extensions/source/propctrlr/pushbuttonnavigation.cxx +++ b/extensions/source/propctrlr/pushbuttonnavigation.cxx @@ -103,7 +103,7 @@ namespace pcr } catch( const Exception& ) { - OSL_ENSURE( sal_False, "PushButtonNavigation::PushButtonNavigation: caught an exception!" ); + OSL_FAIL( "PushButtonNavigation::PushButtonNavigation: caught an exception!" ); } } @@ -142,7 +142,7 @@ namespace pcr } catch( const Exception& ) { - OSL_ENSURE( sal_False, "PushButtonNavigation::getCurrentButtonType: caught an exception!" ); + OSL_FAIL( "PushButtonNavigation::getCurrentButtonType: caught an exception!" ); } return aReturn; } @@ -174,7 +174,7 @@ namespace pcr } catch( const Exception& ) { - OSL_ENSURE( sal_False, "PushButtonNavigation::setCurrentButtonType: caught an exception!" ); + OSL_FAIL( "PushButtonNavigation::setCurrentButtonType: caught an exception!" ); } } @@ -206,7 +206,7 @@ namespace pcr } catch( const Exception& ) { - OSL_ENSURE( sal_False, "PushButtonNavigation::getCurrentButtonTypeState: caught an exception!" ); + OSL_FAIL( "PushButtonNavigation::getCurrentButtonTypeState: caught an exception!" ); } return eState; @@ -237,7 +237,7 @@ namespace pcr } catch( const Exception& ) { - OSL_ENSURE( sal_False, "PushButtonNavigation::getCurrentTargetURL: caught an exception!" ); + OSL_FAIL( "PushButtonNavigation::getCurrentTargetURL: caught an exception!" ); } return aReturn; } @@ -254,7 +254,7 @@ namespace pcr } catch( const Exception& ) { - OSL_ENSURE( sal_False, "PushButtonNavigation::setCurrentTargetURL: caught an exception!" ); + OSL_FAIL( "PushButtonNavigation::setCurrentTargetURL: caught an exception!" ); } } @@ -273,7 +273,7 @@ namespace pcr } catch( const Exception& ) { - OSL_ENSURE( sal_False, "PushButtonNavigation::setCurrentTargetURL: caught an exception!" ); + OSL_FAIL( "PushButtonNavigation::setCurrentTargetURL: caught an exception!" ); } return eState; diff --git a/extensions/source/propctrlr/submissionhandler.cxx b/extensions/source/propctrlr/submissionhandler.cxx index 3a64005d3541..211d021361e0 100644 --- a/extensions/source/propctrlr/submissionhandler.cxx +++ b/extensions/source/propctrlr/submissionhandler.cxx @@ -91,7 +91,7 @@ namespace pcr } catch( const Exception& ) { - OSL_ENSURE( sal_False, "SubmissionHelper::canTriggerSubmissions: caught an exception!" ); + OSL_FAIL( "SubmissionHelper::canTriggerSubmissions: caught an exception!" ); } return false; } @@ -173,7 +173,7 @@ namespace pcr } catch( const Exception& ) { - OSL_ENSURE( sal_False, "SubmissionPropertyHandler::getPropertyValue: caught an exception!" ); + OSL_FAIL( "SubmissionPropertyHandler::getPropertyValue: caught an exception!" ); } return aReturn; @@ -213,12 +213,12 @@ namespace pcr break; default: - OSL_ENSURE( sal_False, "SubmissionPropertyHandler::setPropertyValue: cannot handle this id!" ); + OSL_FAIL( "SubmissionPropertyHandler::setPropertyValue: cannot handle this id!" ); } } catch( const Exception& ) { - OSL_ENSURE( sal_False, "SubmissionPropertyHandler::setPropertyValue: caught an exception!" ); + OSL_FAIL( "SubmissionPropertyHandler::setPropertyValue: caught an exception!" ); } } @@ -318,7 +318,7 @@ namespace pcr break; default: - OSL_ENSURE( sal_False, "SubmissionPropertyHandler::describePropertyLine: cannot handle this id!" ); + OSL_FAIL( "SubmissionPropertyHandler::describePropertyLine: cannot handle this id!" ); return LineDescriptor(); } @@ -352,7 +352,7 @@ namespace pcr break; default: - OSL_ENSURE( sal_False, "SubmissionPropertyHandler::actuatingPropertyChanged: cannot handle this id!" ); + OSL_FAIL( "SubmissionPropertyHandler::actuatingPropertyChanged: cannot handle this id!" ); } } @@ -389,7 +389,7 @@ namespace pcr break; default: - OSL_ENSURE( sal_False, "SubmissionPropertyHandler::convertToPropertyValue: cannot handle this id!" ); + OSL_FAIL( "SubmissionPropertyHandler::convertToPropertyValue: cannot handle this id!" ); } return aPropertyValue; @@ -430,7 +430,7 @@ namespace pcr break; default: - OSL_ENSURE( sal_False, "SubmissionPropertyHandler::convertToControlValue: cannot handle this id!" ); + OSL_FAIL( "SubmissionPropertyHandler::convertToControlValue: cannot handle this id!" ); } return aControlValue; diff --git a/extensions/source/propctrlr/taborder.cxx b/extensions/source/propctrlr/taborder.cxx index 6900e5c6d756..fa7e03149137 100644 --- a/extensions/source/propctrlr/taborder.cxx +++ b/extensions/source/propctrlr/taborder.cxx @@ -269,7 +269,7 @@ namespace pcr } catch( const Exception& ) { - OSL_ENSURE( sal_False, "TabOrderDialog::AutoOrderClickHdl: caught an exception!" ); + OSL_FAIL( "TabOrderDialog::AutoOrderClickHdl: caught an exception!" ); } return 0; diff --git a/extensions/source/propctrlr/unourl.cxx b/extensions/source/propctrlr/unourl.cxx index 63600fc4c827..5e73bef47f1c 100644 --- a/extensions/source/propctrlr/unourl.cxx +++ b/extensions/source/propctrlr/unourl.cxx @@ -61,7 +61,7 @@ namespace pcr } catch( const Exception& ) { - OSL_ENSURE( sal_False, "UnoURL::UnoURL: caught an exception!" ); + OSL_FAIL( "UnoURL::UnoURL: caught an exception!" ); } } diff --git a/extensions/source/propctrlr/xsddatatypes.cxx b/extensions/source/propctrlr/xsddatatypes.cxx index 2b7b99692d87..c536c6f98f9a 100644 --- a/extensions/source/propctrlr/xsddatatypes.cxx +++ b/extensions/source/propctrlr/xsddatatypes.cxx @@ -60,7 +60,7 @@ namespace pcr } catch( const Exception& ) { - OSL_ENSURE( sal_False, "XSDDataType: setSave: caught an exception!" ); + OSL_FAIL( "XSDDataType: setSave: caught an exception!" ); } } @@ -75,7 +75,7 @@ namespace pcr } catch( const Exception& ) { - OSL_ENSURE( sal_False, "XSDDataType: getSave: caught an exception!" ); + OSL_FAIL( "XSDDataType: getSave: caught an exception!" ); } return aReturn; } @@ -90,7 +90,7 @@ namespace pcr } catch( const Exception& ) { - OSL_ENSURE( sal_False, "XSDDataType: getFacet: caught an exception!" ); + OSL_FAIL( "XSDDataType: getFacet: caught an exception!" ); } return aReturn; } @@ -141,7 +141,7 @@ namespace pcr } catch( const Exception& ) { - OSL_ENSURE( sal_False, "XSDDataType::classify: caught an exception!" ); + OSL_FAIL( "XSDDataType::classify: caught an exception!" ); } return nTypeClass; } @@ -167,7 +167,7 @@ namespace pcr } catch( const Exception& ) { - OSL_ENSURE( sal_False, "XSDDataType::setFacet: caught an exception - sure this is the right data type class for this property?" ); + OSL_FAIL( "XSDDataType::setFacet: caught an exception - sure this is the right data type class for this property?" ); } } @@ -181,7 +181,7 @@ namespace pcr } catch( const Exception& ) { - OSL_ENSURE( sal_False, "XSDDataType::hasFacet: caught an exception!" ); + OSL_FAIL( "XSDDataType::hasFacet: caught an exception!" ); } return bReturn; } @@ -195,7 +195,7 @@ namespace pcr } catch( const Exception& ) { - OSL_ENSURE( sal_False, "XSDDataType::getFacet: caught an exception - sure this is the right data type class for this property?" ); + OSL_FAIL( "XSDDataType::getFacet: caught an exception - sure this is the right data type class for this property?" ); } return aReturn; } @@ -241,7 +241,7 @@ namespace pcr } catch( const Exception& ) { - OSL_ENSURE( sal_False, "XSDDataType::copyFacetsFrom: caught an exception!" ); + OSL_FAIL( "XSDDataType::copyFacetsFrom: caught an exception!" ); } } diff --git a/extensions/source/propctrlr/xsdvalidationhelper.cxx b/extensions/source/propctrlr/xsdvalidationhelper.cxx index 7e6440ae5a8c..d0fdac11ccd1 100644 --- a/extensions/source/propctrlr/xsdvalidationhelper.cxx +++ b/extensions/source/propctrlr/xsdvalidationhelper.cxx @@ -82,7 +82,7 @@ namespace pcr } catch( const Exception& ) { - OSL_ENSURE( sal_False, "XSDValidationHelper::XSDValidationHelper: caught an exception while examining the introspectee!" ); + OSL_FAIL( "XSDValidationHelper::XSDValidationHelper: caught an exception while examining the introspectee!" ); } } @@ -103,7 +103,7 @@ namespace pcr } catch( const Exception& ) { - OSL_ENSURE( sal_False, "XSDValidationHelper::getAvailableDataTypeNames: caught an exception!" ); + OSL_FAIL( "XSDValidationHelper::getAvailableDataTypeNames: caught an exception!" ); } } @@ -160,7 +160,7 @@ namespace pcr } catch( const Exception& ) { - OSL_ENSURE( sal_False, "XSDValidationHelper::getValidatingDataTypeName: caught an exception!" ); + OSL_FAIL( "XSDValidationHelper::getValidatingDataTypeName: caught an exception!" ); } return sDataTypeName; } @@ -182,7 +182,7 @@ namespace pcr } catch( const Exception& ) { - OSL_ENSURE( sal_False, "XSDValidationHelper::getDataTypeByName: caught an exception!" ); + OSL_FAIL( "XSDValidationHelper::getDataTypeByName: caught an exception!" ); } return pReturn; @@ -217,7 +217,7 @@ namespace pcr } catch( const Exception& ) { - OSL_ENSURE( sal_False, "XSDValidationHelper::cloneDataType: caught an exception!" ); + OSL_FAIL( "XSDValidationHelper::cloneDataType: caught an exception!" ); } return true; } @@ -234,7 +234,7 @@ namespace pcr if ( !xRepository->hasByName( _rName ) ) { - OSL_ENSURE( sal_False, "XSDValidationHelper::removeDataTypeFromRepository: invalid repository and/or data type!" ); + OSL_FAIL( "XSDValidationHelper::removeDataTypeFromRepository: invalid repository and/or data type!" ); return false; } @@ -242,7 +242,7 @@ namespace pcr } catch( const Exception& ) { - OSL_ENSURE( sal_False, "XSDValidationHelper::removeDataTypeFromRepository: caught an exception!" ); + OSL_FAIL( "XSDValidationHelper::removeDataTypeFromRepository: caught an exception!" ); return false; } return true; @@ -322,7 +322,7 @@ namespace pcr } catch( const Exception& ) { - OSL_ENSURE( sal_False, "XSDValidationHelper::copyDataType: caught an exception!" ); + OSL_FAIL( "XSDValidationHelper::copyDataType: caught an exception!" ); } } @@ -374,7 +374,7 @@ namespace pcr } catch( const Exception& ) { - OSL_ENSURE( sal_False, "XSDValidationHelper::findDefaultFormatForIntrospectee: caught an exception!" ); + OSL_FAIL( "XSDValidationHelper::findDefaultFormatForIntrospectee: caught an exception!" ); } } @@ -401,7 +401,7 @@ namespace pcr } catch( const Exception& ) { - OSL_ENSURE( sal_False, "XSDValidationHelper::getBasicTypeNameForClass: caught an exception!" ); + OSL_FAIL( "XSDValidationHelper::getBasicTypeNameForClass: caught an exception!" ); } return sReturn; diff --git a/extensions/test/ole/cpnt/cpnt.cxx b/extensions/test/ole/cpnt/cpnt.cxx index c7d6661ddf9d..2ee1e3364507 100644 --- a/extensions/test/ole/cpnt/cpnt.cxx +++ b/extensions/test/ole/cpnt/cpnt.cxx @@ -363,7 +363,7 @@ extern "C" sal_Bool SAL_CALL component_writeInfo( void * /*pServiceManager*/, } catch(InvalidRegistryException &) { - OSL_ENSURE( sal_False, "### InvalidRegistryException!\n"); + OSL_FAIL( "### InvalidRegistryException!\n"); } } return sal_False; diff --git a/forms/source/component/ComboBox.cxx b/forms/source/component/ComboBox.cxx index f2c8cbfa2ccf..9b893f5d708a 100644 --- a/forms/source/component/ComboBox.cxx +++ b/forms/source/component/ComboBox.cxx @@ -394,7 +394,7 @@ void SAL_CALL OComboBoxModel::read(const Reference<stario::XObjectInputStream>& } catch( const Exception& ) { - OSL_ENSURE( sal_False, "OComboBoxModel::read: caught an exception while examining the aggregate's string item list!" ); + OSL_FAIL( "OComboBoxModel::read: caught an exception while examining the aggregate's string item list!" ); } // Version diff --git a/forms/source/component/DatabaseForm.cxx b/forms/source/component/DatabaseForm.cxx index 74fab9759d33..a6a14e652f62 100644 --- a/forms/source/component/DatabaseForm.cxx +++ b/forms/source/component/DatabaseForm.cxx @@ -2082,7 +2082,7 @@ void ODatabaseForm::reset_impl(bool _bAproveByListeners) } catch(const Exception&) { - OSL_ENSURE(sal_False, "ODatabaseForm::reset_impl: could not initialize the master-detail-driven parameters!"); + OSL_FAIL("ODatabaseForm::reset_impl: could not initialize the master-detail-driven parameters!"); } } } @@ -2542,7 +2542,7 @@ void SAL_CALL ODatabaseForm::setGroup( const Sequence<Reference<XControlModel> > { // can't throw an exception other than a RuntimeException (which would not be appropriate), // so we ignore (and only assert) this - OSL_ENSURE( sal_False, "ODatabaseForm::setGroup: invalid arguments!" ); + OSL_FAIL( "ODatabaseForm::setGroup: invalid arguments!" ); continue; } diff --git a/forms/source/component/Date.cxx b/forms/source/component/Date.cxx index 74e0444093a1..7a177d9ca6b6 100644 --- a/forms/source/component/Date.cxx +++ b/forms/source/component/Date.cxx @@ -119,7 +119,7 @@ ODateModel::ODateModel(const Reference<XMultiServiceFactory>& _rxFactory) } catch( const Exception& ) { - OSL_ENSURE( sal_False, "ODateModel::ODateModel: caught an exception!" ); + OSL_FAIL( "ODateModel::ODateModel: caught an exception!" ); } osl_decrementInterlockedCount( &m_refCount ); } diff --git a/forms/source/component/Edit.cxx b/forms/source/component/Edit.cxx index d948dec4f392..d745a1b3837a 100644 --- a/forms/source/component/Edit.cxx +++ b/forms/source/component/Edit.cxx @@ -459,7 +459,7 @@ namespace if ( !xSourceInfo.is() || !xDestInfo.is() ) { - OSL_ENSURE( sal_False, "lcl_transferProperties: invalid property set(s)!" ); + OSL_FAIL( "lcl_transferProperties: invalid property set(s)!" ); return; } @@ -496,7 +496,7 @@ namespace sMessage += ::rtl::OString( "\n\nMessage:\n" ); sMessage += ::rtl::OString( e.Message.getStr(), e.Message.getLength(), RTL_TEXTENCODING_ASCII_US ); } - OSL_ENSURE( sal_False, sMessage.getStr() ); + OSL_FAIL( sMessage.getStr() ); #endif } diff --git a/forms/source/component/Filter.cxx b/forms/source/component/Filter.cxx index d5b203249de1..69643053bed8 100644 --- a/forms/source/component/Filter.cxx +++ b/forms/source/component/Filter.cxx @@ -120,13 +120,13 @@ namespace frm { if ( !m_xField.is() ) { - OSL_ENSURE( sal_False, "OFilterControl::ensureInitialized: improperly initialized: no field!" ); + OSL_FAIL( "OFilterControl::ensureInitialized: improperly initialized: no field!" ); return sal_False; } if ( !m_xConnection.is() ) { - OSL_ENSURE( sal_False, "OFilterControl::ensureInitialized: improperly initialized: no connection!" ); + OSL_FAIL( "OFilterControl::ensureInitialized: improperly initialized: no connection!" ); return sal_False; } @@ -144,7 +144,7 @@ namespace frm } if ( !m_xFormatter.is() ) { - OSL_ENSURE( sal_False, "OFilterControl::ensureInitialized: no number formatter!" ); + OSL_FAIL( "OFilterControl::ensureInitialized: no number formatter!" ); // no fallback anymore return sal_False; } @@ -806,7 +806,7 @@ namespace frm Reference< XPropertySet > xControlModel; if ( !(*pValue >>= xControlModel ) || !xControlModel.is() ) { - OSL_ENSURE( sal_False, "OFilterControl::initialize: invalid control model argument!" ); + OSL_FAIL( "OFilterControl::initialize: invalid control model argument!" ); continue; } diff --git a/forms/source/component/FormComponent.cxx b/forms/source/component/FormComponent.cxx index 4eeb9970da33..14c9f4fce067 100644 --- a/forms/source/component/FormComponent.cxx +++ b/forms/source/component/FormComponent.cxx @@ -564,7 +564,7 @@ void OControlModel::readHelpTextCompatibly(const staruno::Reference< stario::XOb } catch(const Exception&) { - OSL_ENSURE(sal_False, "OControlModel::readHelpTextCompatibly: could not forward the property value to the aggregate!"); + OSL_FAIL("OControlModel::readHelpTextCompatibly: could not forward the property value to the aggregate!"); } } @@ -579,7 +579,7 @@ void OControlModel::writeHelpTextCompatibly(const staruno::Reference< stario::XO } catch(const Exception&) { - OSL_ENSURE(sal_False, "OControlModel::writeHelpTextCompatibly: could not retrieve the property value from the aggregate!"); + OSL_FAIL("OControlModel::writeHelpTextCompatibly: could not retrieve the property value from the aggregate!"); } ::comphelper::operator<<( _rxOutStream, sHelpText); } @@ -619,7 +619,7 @@ OControlModel::OControlModel( } catch( const Exception& ) { - OSL_ENSURE( sal_False, "OControlModel::OControlModel: caught an exception!" ); + OSL_FAIL( "OControlModel::OControlModel: caught an exception!" ); } } } @@ -1966,7 +1966,7 @@ void SAL_CALL OBoundControlModel::propertyChange( const PropertyChangeEvent& evt } catch( const Exception& ) { - OSL_ENSURE( sal_False, "OBoundControlModel::propertyChange: could not adjust my binding-controlled property!" ); + OSL_FAIL( "OBoundControlModel::propertyChange: could not adjust my binding-controlled property!" ); } } } @@ -2132,7 +2132,7 @@ sal_Bool OBoundControlModel::connectToField(const Reference<XRowSet>& rForm) } else { - OSL_ENSURE(sal_False, "OBoundControlModel::connectToField: property NAME not supported!"); + OSL_FAIL("OBoundControlModel::connectToField: property NAME not supported!"); impl_setField_noNotify( NULL ); } } @@ -2341,7 +2341,7 @@ void OBoundControlModel::doSetControlValue( const Any& _rValue ) } catch( const Exception& ) { - OSL_ENSURE( sal_False, "OBoundControlModel::doSetControlValue: caught an exception!" ); + OSL_FAIL( "OBoundControlModel::doSetControlValue: caught an exception!" ); } } @@ -2361,7 +2361,7 @@ void OBoundControlModel::onConnectedValidator( ) } catch( const Exception& ) { - OSL_ENSURE( sal_False, "OBoundControlModel::onConnectedValidator: caught an exception!" ); + OSL_FAIL( "OBoundControlModel::onConnectedValidator: caught an exception!" ); } recheckValidity( false ); } @@ -2379,7 +2379,7 @@ void OBoundControlModel::onDisconnectedValidator( ) } catch( const Exception& ) { - OSL_ENSURE( sal_False, "OBoundControlModel::onDisconnectedValidator: caught an exception!" ); + OSL_FAIL( "OBoundControlModel::onDisconnectedValidator: caught an exception!" ); } recheckValidity( false ); } @@ -2467,7 +2467,7 @@ void OBoundControlModel::reset() throw (RuntimeException) } catch( const SQLException& ) { - OSL_ENSURE( sal_False, "OBoundControlModel::reset: caught an SQL exception!" ); + OSL_FAIL( "OBoundControlModel::reset: caught an SQL exception!" ); } // #i24495# - don't count the insert row as "invalid" @@ -2676,7 +2676,7 @@ void OBoundControlModel::disconnectExternalValueBinding( ) } catch( const Exception& ) { - OSL_ENSURE( sal_False, "OBoundControlModel::disconnectExternalValueBinding: caught an exception!" ); + OSL_FAIL( "OBoundControlModel::disconnectExternalValueBinding: caught an exception!" ); } // if the binding also acts as our validator, disconnect the validator, too @@ -3045,7 +3045,7 @@ void OBoundControlModel::recheckValidity( bool _bForceNotification ) } catch( const Exception& ) { - OSL_ENSURE( sal_False, "OBoundControlModel::recheckValidity: caught an exception!" ); + OSL_FAIL( "OBoundControlModel::recheckValidity: caught an exception!" ); } } diff --git a/forms/source/component/ListBox.cxx b/forms/source/component/ListBox.cxx index a489f50ffeda..a54377c73f27 100644 --- a/forms/source/component/ListBox.cxx +++ b/forms/source/component/ListBox.cxx @@ -546,7 +546,7 @@ namespace frm } catch( const Exception& ) { - OSL_ENSURE( sal_False, "OComboBoxModel::read: caught an exception while examining the aggregate's string item list!" ); + OSL_FAIL( "OComboBoxModel::read: caught an exception while examining the aggregate's string item list!" ); } // Version diff --git a/forms/source/component/clickableimage.cxx b/forms/source/component/clickableimage.cxx index dc839f679c4b..bcccac7f7822 100644 --- a/forms/source/component/clickableimage.cxx +++ b/forms/source/component/clickableimage.cxx @@ -439,7 +439,7 @@ namespace frm } catch( const Exception& e ) { - OSL_ENSURE( sal_False, "OClickableImageBaseControl::implSubmit: caught an unknown exception!" ); + OSL_FAIL( "OClickableImageBaseControl::implSubmit: caught an unknown exception!" ); throw WrappedTargetException( ::rtl::OUString(), *this, makeAny( e ) ); } } diff --git a/forms/source/component/formcontrolfont.cxx b/forms/source/component/formcontrolfont.cxx index c9837d5ee862..f936dc65b86c 100644 --- a/forms/source/component/formcontrolfont.cxx +++ b/forms/source/component/formcontrolfont.cxx @@ -123,7 +123,7 @@ namespace frm break; default: - OSL_ENSURE( sal_False, "lcl_extractFontDescriptorAggregate: invalid handle!" ); + OSL_FAIL( "lcl_extractFontDescriptorAggregate: invalid handle!" ); break; } return aValue; diff --git a/forms/source/component/refvaluecomponent.cxx b/forms/source/component/refvaluecomponent.cxx index 9fdf49d5117d..b586e393ea33 100644 --- a/forms/source/component/refvaluecomponent.cxx +++ b/forms/source/component/refvaluecomponent.cxx @@ -267,7 +267,7 @@ namespace frm } catch( const Exception& ) { - OSL_ENSURE( sal_False, "OReferenceValueComponent::translateControlValueToExternalValue: caught an exception!" ); + OSL_FAIL( "OReferenceValueComponent::translateControlValueToExternalValue: caught an exception!" ); } return aExternalValue; diff --git a/forms/source/component/scrollbar.cxx b/forms/source/component/scrollbar.cxx index 98c47b258d51..d8b230a03b3d 100644 --- a/forms/source/component/scrollbar.cxx +++ b/forms/source/component/scrollbar.cxx @@ -98,7 +98,7 @@ namespace frm aExternalDoubleValue <<= (double)nScrollValue; else { - OSL_ENSURE( sal_False, "translateControlIntToExternalDoubleValue: no integer scroll value!" ); + OSL_FAIL( "translateControlIntToExternalDoubleValue: no integer scroll value!" ); // aExternalDoubleValue is void here, which is okay for this purpose ... } @@ -231,14 +231,14 @@ namespace frm //------------------------------------------------------------------------------ Any OScrollBarModel::translateDbColumnToControlValue( ) { - OSL_ENSURE( sal_False, "OScrollBarModel::commitControlValueToDbColumn: never to be called (we're not bound)!" ); + OSL_FAIL( "OScrollBarModel::commitControlValueToDbColumn: never to be called (we're not bound)!" ); return Any(); } //------------------------------------------------------------------------------ sal_Bool OScrollBarModel::commitControlValueToDbColumn( bool /*_bPostReset*/ ) { - OSL_ENSURE( sal_False, "OScrollBarModel::commitControlValueToDbColumn: never to be called (we're not bound)!" ); + OSL_FAIL( "OScrollBarModel::commitControlValueToDbColumn: never to be called (we're not bound)!" ); return sal_True; } diff --git a/forms/source/component/spinbutton.cxx b/forms/source/component/spinbutton.cxx index 06c6d4f63618..cef0c2d1e223 100644 --- a/forms/source/component/spinbutton.cxx +++ b/forms/source/component/spinbutton.cxx @@ -187,14 +187,14 @@ namespace frm //------------------------------------------------------------------------------ Any OSpinButtonModel::translateDbColumnToControlValue( ) { - OSL_ENSURE( sal_False, "OSpinButtonModel::commitControlValueToDbColumn: never to be called (we're not bound)!" ); + OSL_FAIL( "OSpinButtonModel::commitControlValueToDbColumn: never to be called (we're not bound)!" ); return Any(); } //------------------------------------------------------------------------------ sal_Bool OSpinButtonModel::commitControlValueToDbColumn( bool /*_bPostReset*/ ) { - OSL_ENSURE( sal_False, "OSpinButtonModel::commitControlValueToDbColumn: never to be called (we're not bound)!" ); + OSL_FAIL( "OSpinButtonModel::commitControlValueToDbColumn: never to be called (we're not bound)!" ); return sal_True; } diff --git a/forms/source/misc/limitedformats.cxx b/forms/source/misc/limitedformats.cxx index a4707f03a25d..6066f8f522ce 100644 --- a/forms/source/misc/limitedformats.cxx +++ b/forms/source/misc/limitedformats.cxx @@ -81,7 +81,7 @@ namespace frm return s_aSystem; } - OSL_ENSURE(sal_False, "getLocale: invalid enum value!"); + OSL_FAIL("getLocale: invalid enum value!"); return s_aSystem; } @@ -135,7 +135,7 @@ namespace frm } } - OSL_ENSURE(sal_False, "lcl_getFormatTable: invalid id!"); + OSL_FAIL("lcl_getFormatTable: invalid id!"); return NULL; } @@ -199,7 +199,7 @@ namespace frm } catch(const Exception&) { - OSL_ENSURE(sal_False, "OLimitedFormats::ensureTableInitialized: adding the key to the formats collection failed!"); + OSL_FAIL("OLimitedFormats::ensureTableInitialized: adding the key to the formats collection failed!"); } #endif } @@ -243,7 +243,7 @@ namespace frm } catch(const Exception&) { - OSL_ENSURE(sal_False, "OLimitedFormats::setAggregateSet: invalid handle!"); + OSL_FAIL("OLimitedFormats::setAggregateSet: invalid handle!"); } } #endif diff --git a/forms/source/misc/listenercontainers.cxx b/forms/source/misc/listenercontainers.cxx index 56297368ff74..7e78c875df3b 100644 --- a/forms/source/misc/listenercontainers.cxx +++ b/forms/source/misc/listenercontainers.cxx @@ -60,7 +60,7 @@ namespace frm _rxListener->resetted( _rEvent ); break; default: - OSL_ENSURE( sal_False, "ResetListeners::implNotify: invalid notification type!" ); + OSL_FAIL( "ResetListeners::implNotify: invalid notification type!" ); } return true; } diff --git a/forms/source/richtext/featuredispatcher.cxx b/forms/source/richtext/featuredispatcher.cxx index 7514d4a2a35f..fdc08a1f7a69 100644 --- a/forms/source/richtext/featuredispatcher.cxx +++ b/forms/source/richtext/featuredispatcher.cxx @@ -148,7 +148,7 @@ namespace frm } catch( const Exception& ) { - OSL_ENSURE( sal_False, "ORichTextFeatureDispatcher::doNotify: caught an exception!" ); + OSL_FAIL( "ORichTextFeatureDispatcher::doNotify: caught an exception!" ); } } } diff --git a/forms/source/richtext/richtextcontrol.cxx b/forms/source/richtext/richtextcontrol.cxx index 42f6dad4ca41..beab78376ff2 100644 --- a/forms/source/richtext/richtextcontrol.cxx +++ b/forms/source/richtext/richtextcontrol.cxx @@ -701,7 +701,7 @@ namespace frm Reference< XDispatch > xReturn; if ( !GetWindow() ) { - OSL_ENSURE( sal_False, "ORichTextPeer::queryDispatch: already disposed?" ); + OSL_FAIL( "ORichTextPeer::queryDispatch: already disposed?" ); return xReturn; } diff --git a/forms/source/richtext/richtextimplcontrol.cxx b/forms/source/richtext/richtextimplcontrol.cxx index c0c6fe2a7cdd..e292a6f9ef08 100644 --- a/forms/source/richtext/richtextimplcontrol.cxx +++ b/forms/source/richtext/richtextimplcontrol.cxx @@ -176,7 +176,7 @@ namespace frm StateCache::const_iterator aCachedStatePos = m_aLastKnownStates.find( _nAttributeId ); if ( aCachedStatePos == m_aLastKnownStates.end() ) { - OSL_ENSURE( sal_False, "RichTextControlImpl::getAttributeState: Don't ask for the state of an attribute which I never encountered!" ); + OSL_FAIL( "RichTextControlImpl::getAttributeState: Don't ask for the state of an attribute which I never encountered!" ); return AttributeState( eIndetermined ); } return aCachedStatePos->second; diff --git a/forms/source/richtext/richtextmodel.cxx b/forms/source/richtext/richtextmodel.cxx index e38757211fe6..c5f91a6fec28 100644 --- a/forms/source/richtext/richtextmodel.cxx +++ b/forms/source/richtext/richtextmodel.cxx @@ -549,7 +549,7 @@ namespace frm } catch( const Exception& ) { - OSL_ENSURE( sal_False, "ORichTextModel::getEditEngine: caught an exception!" ); + OSL_FAIL( "ORichTextModel::getEditEngine: caught an exception!" ); } } return pEngine; diff --git a/forms/source/richtext/richtextvclcontrol.cxx b/forms/source/richtext/richtextvclcontrol.cxx index d5b9d560dd3f..1f47f4cabe7c 100644 --- a/forms/source/richtext/richtextvclcontrol.cxx +++ b/forms/source/richtext/richtextvclcontrol.cxx @@ -105,7 +105,7 @@ namespace frm SfxItemSet aToApplyAttributes( getView().GetEmptyItemSet() ); if ( !m_pImpl->executeAttribute( getView().GetAttribs(), aToApplyAttributes, _nAttributeId, _pArgument, m_pImpl->getSelectedScriptType() ) ) { - OSL_ENSURE( sal_False, "RichTextControl::executeAttribute: cannot handle the given attribute!" ); + OSL_FAIL( "RichTextControl::executeAttribute: cannot handle the given attribute!" ); return; } diff --git a/forms/source/richtext/rtattributehandler.cxx b/forms/source/richtext/rtattributehandler.cxx index 157f3b1244a5..4e1a7d5b48fb 100644 --- a/forms/source/richtext/rtattributehandler.cxx +++ b/forms/source/richtext/rtattributehandler.cxx @@ -112,7 +112,7 @@ namespace frm //-------------------------------------------------------------------- AttributeCheckState AttributeHandler::implGetCheckState( const SfxPoolItem& /*_rItem*/ ) const { - OSL_ENSURE( sal_False, "AttributeHandler::implGetCheckState: not to be called!" ); + OSL_FAIL( "AttributeHandler::implGetCheckState: not to be called!" ); return eIndetermined; } @@ -231,7 +231,7 @@ namespace frm case SID_ATTR_PARA_ADJUST_RIGHT : m_eAdjust = SVX_ADJUST_RIGHT; break; case SID_ATTR_PARA_ADJUST_BLOCK : m_eAdjust = SVX_ADJUST_BLOCK; break; default: - OSL_ENSURE( sal_False, "ParaAlignmentHandler::ParaAlignmentHandler: invalid slot!" ); + OSL_FAIL( "ParaAlignmentHandler::ParaAlignmentHandler: invalid slot!" ); break; } } @@ -266,7 +266,7 @@ namespace frm case SID_ATTR_PARA_LINESPACE_15: m_nLineSpace = 150; break; case SID_ATTR_PARA_LINESPACE_20: m_nLineSpace = 200; break; default: - OSL_ENSURE( sal_False, "LineSpacingHandler::LineSpacingHandler: invalid slot!" ); + OSL_FAIL( "LineSpacingHandler::LineSpacingHandler: invalid slot!" ); break; } } @@ -308,7 +308,7 @@ namespace frm case SID_SET_SUPER_SCRIPT : m_eEscapement = SVX_ESCAPEMENT_SUPERSCRIPT; break; case SID_SET_SUB_SCRIPT : m_eEscapement = SVX_ESCAPEMENT_SUBSCRIPT; break; default: - OSL_ENSURE( sal_False, "EscapementHandler::EscapementHandler: invalid slot!" ); + OSL_FAIL( "EscapementHandler::EscapementHandler: invalid slot!" ); break; } } @@ -372,7 +372,7 @@ namespace frm DELETEZ( pCorrectWich ); } else - OSL_ENSURE( sal_False, "SlotHandler::executeAttribute: need attributes to do something!" ); + OSL_FAIL( "SlotHandler::executeAttribute: need attributes to do something!" ); } //==================================================================== @@ -461,7 +461,7 @@ namespace frm case SID_ATTR_PARA_LEFT_TO_RIGHT: m_eParagraphDirection = FRMDIR_HORI_LEFT_TOP; m_eDefaultAdjustment = SVX_ADJUST_LEFT; break; case SID_ATTR_PARA_RIGHT_TO_LEFT: m_eParagraphDirection = FRMDIR_HORI_RIGHT_TOP; m_eDefaultAdjustment = SVX_ADJUST_RIGHT; break; default: - OSL_ENSURE( sal_False, "ParagraphDirectionHandler::ParagraphDirectionHandler: invalid attribute id!" ); + OSL_FAIL( "ParagraphDirectionHandler::ParagraphDirectionHandler: invalid attribute id!" ); } if ( SVX_ADJUST_RIGHT == m_eDefaultAdjustment ) diff --git a/forms/source/richtext/specialdispatchers.cxx b/forms/source/richtext/specialdispatchers.cxx index d384a670a2cd..708281e041a8 100644 --- a/forms/source/richtext/specialdispatchers.cxx +++ b/forms/source/richtext/specialdispatchers.cxx @@ -189,7 +189,7 @@ namespace frm return new SfxBoolItem( (WhichId)m_nAttributeId, bEnable ); } - OSL_ENSURE( sal_False, "OAsianFontLayoutDispatcher::convertDispatchArgsToItem: did not find the one and only argument!" ); + OSL_FAIL( "OAsianFontLayoutDispatcher::convertDispatchArgsToItem: did not find the one and only argument!" ); return NULL; } diff --git a/forms/source/runtime/formoperations.cxx b/forms/source/runtime/formoperations.cxx index 5bca1a5447a6..c984b9f1d5c6 100644 --- a/forms/source/runtime/formoperations.cxx +++ b/forms/source/runtime/formoperations.cxx @@ -422,13 +422,13 @@ namespace frm break; default: - OSL_ENSURE( sal_False, "FormOperations::getState: unknown feature id!" ); + OSL_FAIL( "FormOperations::getState: unknown feature id!" ); break; } } catch( const Exception& ) { - OSL_ENSURE( sal_False, "FormOperations::getState: caught an exception!" ); + OSL_FAIL( "FormOperations::getState: caught an exception!" ); } return aState; @@ -983,7 +983,7 @@ namespace frm } catch( Exception& ) { - OSL_ENSURE( sal_False, "FormOperations::propertyChange: caught an exception while updating the parser!" ); + OSL_FAIL( "FormOperations::propertyChange: caught an exception while updating the parser!" ); } impl_invalidateAllSupportedFeatures_nothrow( aGuard ); } @@ -1181,7 +1181,7 @@ namespace frm } catch( const Exception& ) { - OSL_ENSURE( sal_False, "FormOperations::impl_ensureInitializedParser_nothrow: caught an exception!" ); + OSL_FAIL( "FormOperations::impl_ensureInitializedParser_nothrow: caught an exception!" ); } m_bInitializedParser = true; @@ -1210,7 +1210,7 @@ namespace frm } catch( const Exception& ) { - OSL_ENSURE( sal_False, "FormOperations::impl_disposeParser_nothrow: caught an exception!" ); + OSL_FAIL( "FormOperations::impl_disposeParser_nothrow: caught an exception!" ); } } @@ -1518,7 +1518,7 @@ namespace frm } catch( const Exception& ) { - OSL_ENSURE( sal_False, "FormOperations::impl_executeAutoSort_throw: caught an exception while setting the parser properties!" ); + OSL_FAIL( "FormOperations::impl_executeAutoSort_throw: caught an exception while setting the parser properties!" ); } @@ -1532,7 +1532,7 @@ namespace frm } catch( const Exception& ) { - OSL_ENSURE( sal_False, "FormOperations::impl_executeAutoSort_throw: could not reset the form to it's original state!" ); + OSL_FAIL( "FormOperations::impl_executeAutoSort_throw: could not reset the form to it's original state!" ); } } @@ -1591,7 +1591,7 @@ namespace frm } catch( const Exception& ) { - OSL_ENSURE( sal_False, "FormOperations::impl_executeAutoFilter_throw: caught an exception while setting the parser properties!" ); + OSL_FAIL( "FormOperations::impl_executeAutoFilter_throw: caught an exception while setting the parser properties!" ); } @@ -1606,7 +1606,7 @@ namespace frm } catch( const Exception& ) { - OSL_ENSURE( sal_False, "FormOperations::impl_executeAutoFilter_throw: could not reset the form to it's original state!" ); + OSL_FAIL( "FormOperations::impl_executeAutoFilter_throw: could not reset the form to it's original state!" ); } } diff --git a/forms/source/solar/control/navtoolbar.cxx b/forms/source/solar/control/navtoolbar.cxx index f87cd2c9d3a6..5112bb442ab7 100644 --- a/forms/source/solar/control/navtoolbar.cxx +++ b/forms/source/solar/control/navtoolbar.cxx @@ -466,7 +466,7 @@ namespace frm } break; default: - OSL_ENSURE( sal_False, "NavigationToolBar::ShowFunctionGroup: invalid group id!" ); + OSL_FAIL( "NavigationToolBar::ShowFunctionGroup: invalid group id!" ); } if ( pGroupIds ) @@ -485,7 +485,7 @@ namespace frm case eRecordActions : nIndicatorItem = FormFeature::SaveRecordChanges; break; case eFilterSort : nIndicatorItem = FormFeature::SortAscending; break; default: - OSL_ENSURE( sal_False, "NavigationToolBar::IsFunctionGroupVisible: invalid group id!" ); + OSL_FAIL( "NavigationToolBar::IsFunctionGroupVisible: invalid group id!" ); } return m_pToolbar->IsItemVisible( nIndicatorItem ); diff --git a/forms/source/xforms/convert.cxx b/forms/source/xforms/convert.cxx index b03132ddd85b..f0db80bdaacc 100644 --- a/forms/source/xforms/convert.cxx +++ b/forms/source/xforms/convert.cxx @@ -565,7 +565,7 @@ Convert::Any_t Convert::toAny( const rtl::OUString& rValue, switch( _nWhitespaceTreatment ) { default: - OSL_ENSURE( sal_False, "Convert::convertWhitespace: invalid whitespace treatment constant!" ); + OSL_FAIL( "Convert::convertWhitespace: invalid whitespace treatment constant!" ); // NO break case com::sun::star::xsd::WhiteSpaceTreatment::Preserve: sConverted = _rString; diff --git a/forms/source/xforms/submission.cxx b/forms/source/xforms/submission.cxx index aece48afe574..1e6b22f42bf6 100644 --- a/forms/source/xforms/submission.cxx +++ b/forms/source/xforms/submission.cxx @@ -336,7 +336,7 @@ bool Submission::doSubmit( const Reference< XInteractionHandler >& xHandler ) new CSubmissionGet( getAction(), aFragment)); else { - OSL_ENSURE(sal_False, "Unsupported xforms submission method"); + OSL_FAIL("Unsupported xforms submission method"); return false; } @@ -570,7 +570,7 @@ void SAL_CALL Submission::submitWithInteraction( } catch( const VetoException& ) { - OSL_ENSURE( sal_False, "Model::submit: Hmm. How can a single submission have a veto right?" ); + OSL_FAIL( "Model::submit: Hmm. How can a single submission have a veto right?" ); // allowed to leave throw; } diff --git a/forms/source/xforms/submission/replace.cxx b/forms/source/xforms/submission/replace.cxx index cfcdb1626439..9ac1f08eb5ff 100644 --- a/forms/source/xforms/submission/replace.cxx +++ b/forms/source/xforms/submission/replace.cxx @@ -112,7 +112,7 @@ CSubmission::SubmissionResult CSubmission::replace(const ::rtl::OUString& aRepla } catch (Exception& e) { ::rtl::OString aMsg("Exception during replace:\n"); aMsg += OUStringToOString(e.Message, RTL_TEXTENCODING_UTF8); - OSL_ENSURE(sal_False, aMsg.getStr()); + OSL_FAIL(aMsg.getStr()); } return CSubmission::UNKNOWN_ERROR; } diff --git a/forms/source/xforms/submission/serialization_app_xml.cxx b/forms/source/xforms/submission/serialization_app_xml.cxx index f7262c527045..b9e06d29f3a5 100644 --- a/forms/source/xforms/submission/serialization_app_xml.cxx +++ b/forms/source/xforms/submission/serialization_app_xml.cxx @@ -91,7 +91,7 @@ CSerializationAppXML::serialize_node(const CSS::uno::Reference< CSS::xml::dom::X } else { // can't get tunnel to native backend // logic for generic implementation could be implemented here... - OSL_ENSURE(sal_False, "unkown dom implementation, cannot serialize"); + OSL_FAIL("unkown dom implementation, cannot serialize"); return; } } diff --git a/forms/source/xforms/submission/submission_get.cxx b/forms/source/xforms/submission/submission_get.cxx index d7d0d005cb67..e4b99f675af5 100644 --- a/forms/source/xforms/submission/submission_get.cxx +++ b/forms/source/xforms/submission/submission_get.cxx @@ -107,12 +107,12 @@ CSubmission::SubmissionResult CSubmissionGet::submit(const CSS::uno::Reference< try { m_aResultStream = aContent.openStream(); } catch (Exception&) { - OSL_ENSURE(sal_False, "Cannot open reply stream from content"); + OSL_FAIL("Cannot open reply stream from content"); } } catch (Exception&) { // XXX - OSL_ENSURE(sal_False, "Exception during UCB operatration."); + OSL_FAIL("Exception during UCB operatration."); return UNKNOWN_ERROR; } diff --git a/forms/source/xforms/submission/submission_post.cxx b/forms/source/xforms/submission/submission_post.cxx index d7a92c885964..b991a31a420e 100644 --- a/forms/source/xforms/submission/submission_post.cxx +++ b/forms/source/xforms/submission/submission_post.cxx @@ -81,11 +81,11 @@ CSubmission::SubmissionResult CSubmissionPost::submit(const CSS::uno::Reference< try { m_aResultStream = aSink->getInputStream(); } catch (Exception&) { - OSL_ENSURE(sal_False, "Cannot open reply stream from content"); + OSL_FAIL("Cannot open reply stream from content"); } } catch (Exception&) { - OSL_ENSURE(sal_False, "Exception during UCB operatration."); + OSL_FAIL("Exception during UCB operatration."); return UNKNOWN_ERROR; } diff --git a/forms/source/xforms/submission/submission_put.cxx b/forms/source/xforms/submission/submission_put.cxx index 98774af3f1e0..6ffb98c6ac4a 100644 --- a/forms/source/xforms/submission/submission_put.cxx +++ b/forms/source/xforms/submission/submission_put.cxx @@ -72,7 +72,7 @@ CSubmission::SubmissionResult CSubmissionPut::submit(const CSS::uno::Reference< } catch (Exception&) { // XXX - OSL_ENSURE(sal_False, "Exception during UCB operatration."); + OSL_FAIL("Exception during UCB operatration."); return UNKNOWN_ERROR; } diff --git a/package/source/xstor/owriteablestream.cxx b/package/source/xstor/owriteablestream.cxx index bb1eb8598705..99ad649a4d28 100644 --- a/package/source/xstor/owriteablestream.cxx +++ b/package/source/xstor/owriteablestream.cxx @@ -125,7 +125,7 @@ void SetEncryptionKeyProperty_Impl( const uno::Reference< beans::XPropertySet >& { ::package::StaticAddLog( aException.Message ); ::package::StaticAddLog( ::rtl::OUString( RTL_CONSTASCII_USTRINGPARAM( OSL_LOG_PREFIX "Can't set encryption") ) ); - OSL_ENSURE( sal_False, "Can't write encryption related properties!\n" ); + OSL_FAIL( "Can't write encryption related properties!\n" ); throw io::IOException(); // TODO } } @@ -146,7 +146,7 @@ uno::Any GetEncryptionKeyProperty_Impl( const uno::Reference< beans::XPropertySe ::package::StaticAddLog( aException.Message ); ::package::StaticAddLog( ::rtl::OUString( RTL_CONSTASCII_USTRINGPARAM( OSL_LOG_PREFIX "Can't get encryption property" ) ) ); - OSL_ENSURE( sal_False, "Can't get encryption related properties!\n" ); + OSL_FAIL( "Can't get encryption related properties!\n" ); throw io::IOException(); // TODO } } @@ -377,7 +377,7 @@ sal_Bool OWriteStream_Impl::IsEncrypted() uno::Any aValue = xPropSet->getPropertyValue( ::rtl::OUString(RTL_CONSTASCII_USTRINGPARAM("WasEncrypted") ) ); if ( !( aValue >>= bWasEncr ) ) { - OSL_ENSURE( sal_False, "The property WasEncrypted has wrong type!\n" ); + OSL_FAIL( "The property WasEncrypted has wrong type!\n" ); } } @@ -388,7 +388,7 @@ sal_Bool OWriteStream_Impl::IsEncrypted() { if ( !( m_aProps[nInd].Value >>= bToBeEncr ) ) { - OSL_ENSURE( sal_False, "The property has wrong type!\n" ); + OSL_FAIL( "The property has wrong type!\n" ); } } } @@ -1158,13 +1158,13 @@ uno::Sequence< beans::PropertyValue > OWriteStream_Impl::ReadPackageStreamProper AddLog( aException.Message ); AddLog( ::rtl::OUString( RTL_CONSTASCII_USTRINGPARAM( OSL_LOG_PREFIX "Quiet exception" ) ) ); - OSL_ENSURE( sal_False, "A property can't be retrieved!\n" ); + OSL_FAIL( "A property can't be retrieved!\n" ); } } } else { - OSL_ENSURE( sal_False, "Can not get properties from a package stream!\n" ); + OSL_FAIL( "Can not get properties from a package stream!\n" ); throw uno::RuntimeException(); } @@ -1309,7 +1309,7 @@ uno::Reference< io::XStream > OWriteStream_Impl::GetStream( sal_Int32 nStreamMod AddLog( aException.Message ); AddLog( ::rtl::OUString( RTL_CONSTASCII_USTRINGPARAM( OSL_LOG_PREFIX "Quiet exception" ) ) ); - OSL_ENSURE( sal_False, "Can't write encryption related properties!\n" ); + OSL_FAIL( "Can't write encryption related properties!\n" ); SetEncryptionKeyProperty_Impl( xPropertySet, uno::Sequence< sal_Int8 >() ); throw io::IOException(); // TODO: } @@ -1655,7 +1655,7 @@ void OWriteStream_Impl::GetCopyOfLastCommit( uno::Reference< io::XStream >& xTar if ( !xDataToCopy.is() ) { - OSL_ENSURE( sal_False, "Encrypted ZipStream must already have input stream inside!\n" ); + OSL_FAIL( "Encrypted ZipStream must already have input stream inside!\n" ); SetEncryptionKeyProperty_Impl( xPropertySet, uno::Sequence< sal_Int8 >() ); } } @@ -1667,7 +1667,7 @@ void OWriteStream_Impl::GetCopyOfLastCommit( uno::Reference< io::XStream >& xTar if ( !xDataToCopy.is() ) { - OSL_ENSURE( sal_False, "Encrypted ZipStream must already have input stream inside!\n" ); + OSL_FAIL( "Encrypted ZipStream must already have input stream inside!\n" ); SetEncryptionKeyProperty_Impl( xPropertySet, uno::Sequence< sal_Int8 >() ); AddLog( aWrongPasswordException.Message ); AddLog( ::rtl::OUString( RTL_CONSTASCII_USTRINGPARAM( OSL_LOG_PREFIX "Rethrow" ) ) ); @@ -1684,7 +1684,7 @@ void OWriteStream_Impl::GetCopyOfLastCommit( uno::Reference< io::XStream >& xTar } catch( uno::Exception& aException ) { - OSL_ENSURE( sal_False, "Can't open encrypted stream!\n" ); + OSL_FAIL( "Can't open encrypted stream!\n" ); SetEncryptionKeyProperty_Impl( xPropertySet, uno::Sequence< sal_Int8 >() ); AddLog( aException.Message ); AddLog( ::rtl::OUString( RTL_CONSTASCII_USTRINGPARAM( OSL_LOG_PREFIX "Rethrow" ) ) ); @@ -1963,7 +1963,7 @@ void OWriteStream::CopyToStreamInternally_Impl( const uno::Reference< io::XStrea m_pImpl->AddLog( ::rtl::OUString( RTL_CONSTASCII_USTRINGPARAM( OSL_LOG_PREFIX "Quiet exception" ) ) ); // TODO: set the stoream in invalid state or dispose - OSL_ENSURE( sal_False, "The stream become invalid during copiing!\n" ); + OSL_FAIL( "The stream become invalid during copiing!\n" ); throw uno::RuntimeException(); } @@ -2581,7 +2581,7 @@ void SAL_CALL OWriteStream::truncate() if ( !xTruncate.is() ) { - OSL_ENSURE( sal_False, "The output stream must support XTruncate interface!\n" ); + OSL_FAIL( "The output stream must support XTruncate interface!\n" ); throw uno::RuntimeException(); } diff --git a/package/source/xstor/switchpersistencestream.cxx b/package/source/xstor/switchpersistencestream.cxx index f43f96dd5744..1de56c2163ee 100644 --- a/package/source/xstor/switchpersistencestream.cxx +++ b/package/source/xstor/switchpersistencestream.cxx @@ -372,7 +372,7 @@ void SAL_CALL SwitchablePersistenceStream::flush( ) if ( !m_pStreamData || m_pStreamData->m_bInStreamBased ) { - OSL_ENSURE( sal_False, "flush() is not acceptable!\n" ); + OSL_FAIL( "flush() is not acceptable!\n" ); return; // in future throw exception, for now some code might call flush() on closed stream // since file ucp implementation allows it diff --git a/package/source/xstor/xfactory.cxx b/package/source/xstor/xfactory.cxx index e0e1ce8148e4..80be2484a307 100644 --- a/package/source/xstor/xfactory.cxx +++ b/package/source/xstor/xfactory.cxx @@ -134,7 +134,7 @@ uno::Reference< uno::XInterface > SAL_CALL OStorageFactory::createInstanceWithAr { if( !( aArguments[1] >>= nStorageMode ) ) { - OSL_ENSURE( sal_False, "Wrong second argument!\n" ); + OSL_FAIL( "Wrong second argument!\n" ); throw lang::IllegalArgumentException(); // TODO: } // it's allways possible to read written storage in this implementation @@ -154,13 +154,13 @@ uno::Reference< uno::XInterface > SAL_CALL OStorageFactory::createInstanceWithAr { if ( !aURL.getLength() ) { - OSL_ENSURE( sal_False, "Empty URL is provided!\n" ); + OSL_FAIL( "Empty URL is provided!\n" ); throw lang::IllegalArgumentException(); // TODO: } if ( aURL.equalsIgnoreAsciiCaseAsciiL( "vnd.sun.star.pkg", 16 ) ) { - OSL_ENSURE( sal_False, "Packages URL's are not valid for storages!\n" ); // ??? + OSL_FAIL( "Packages URL's are not valid for storages!\n" ); // ??? throw lang::IllegalArgumentException(); // TODO: } @@ -179,7 +179,7 @@ uno::Reference< uno::XInterface > SAL_CALL OStorageFactory::createInstanceWithAr } else if ( !( aArguments[0] >>= xStream ) && !( aArguments[0] >>= xInputStream ) ) { - OSL_ENSURE( sal_False, "Wrong first argument!\n" ); + OSL_FAIL( "Wrong first argument!\n" ); throw uno::Exception(); // TODO: Illegal argument } @@ -240,12 +240,12 @@ uno::Reference< uno::XInterface > SAL_CALL OStorageFactory::createInstanceWithAr throw lang::IllegalArgumentException( ::rtl::OUString( RTL_CONSTASCII_USTRINGPARAM( OSL_LOG_PREFIX ) ), uno::Reference< uno::XInterface >(), 1 ); } else - OSL_ENSURE( sal_False, "Unacceptable property, will be ignored!\n" ); + OSL_FAIL( "Unacceptable property, will be ignored!\n" ); } } else { - OSL_ENSURE( sal_False, "Wrong third argument!\n" ); + OSL_FAIL( "Wrong third argument!\n" ); throw uno::Exception(); // TODO: Illegal argument } @@ -262,7 +262,7 @@ uno::Reference< uno::XInterface > SAL_CALL OStorageFactory::createInstanceWithAr if ( !xSeekable.is() ) { // TODO: wrap stream to let it be seekable - OSL_ENSURE( sal_False, "Nonseekable streams are not supported for now!\n" ); + OSL_FAIL( "Nonseekable streams are not supported for now!\n" ); } if ( !CheckPackageSignature_Impl( xInputStream, xSeekable ) ) @@ -282,7 +282,7 @@ uno::Reference< uno::XInterface > SAL_CALL OStorageFactory::createInstanceWithAr if ( !xSeekable.is() ) { // TODO: wrap stream to let it be seekable - OSL_ENSURE( sal_False, "Nonseekable streams are not supported for now!\n" ); + OSL_FAIL( "Nonseekable streams are not supported for now!\n" ); } if ( !CheckPackageSignature_Impl( xStream->getInputStream(), xSeekable ) ) diff --git a/package/source/xstor/xstorage.cxx b/package/source/xstor/xstorage.cxx index 79728a00a9d6..1f7b0dd9daf0 100644 --- a/package/source/xstor/xstorage.cxx +++ b/package/source/xstor/xstorage.cxx @@ -228,7 +228,7 @@ OStorage_Impl::OStorage_Impl( uno::Reference< io::XInputStream > xInputStream, if ( m_nStorageMode & embed::ElementModes::WRITE ) { // check that the stream allows to write - OSL_ENSURE( sal_False, "No stream for writing is provided!\n" ); + OSL_FAIL( "No stream for writing is provided!\n" ); } } @@ -655,7 +655,7 @@ void OStorage_Impl::ReadContents() if ( !xNamed.is() ) { - OSL_ENSURE( sal_False, "XNamed is not supported!\n" ); + OSL_FAIL( "XNamed is not supported!\n" ); throw uno::RuntimeException( ::rtl::OUString( RTL_CONSTASCII_USTRINGPARAM( OSL_LOG_PREFIX ) ), uno::Reference< uno::XInterface >() ); } @@ -689,7 +689,7 @@ void OStorage_Impl::ReadContents() AddLog( aNoSuchElementException.Message ); AddLog( ::rtl::OUString( RTL_CONSTASCII_USTRINGPARAM( OSL_LOG_PREFIX "NoSuchElement" ) ) ); - OSL_ENSURE( sal_False, "hasMoreElements() implementation has problems!\n" ); + OSL_FAIL( "hasMoreElements() implementation has problems!\n" ); break; } } @@ -911,7 +911,7 @@ void OStorage_Impl::CopyStorageElement( SotElement_Impl* pElement, } else if ( m_nStorageType != embed::StorageFormats::PACKAGE ) { - OSL_ENSURE( sal_False, "Encryption is only supported in package storage!\n" ); + OSL_FAIL( "Encryption is only supported in package storage!\n" ); throw io::IOException( ::rtl::OUString( RTL_CONSTASCII_USTRINGPARAM( OSL_LOG_PREFIX ) ), uno::Reference< uno::XInterface >() ); } else if ( pElement->m_pStream->HasCachedEncryptionData() @@ -4714,7 +4714,7 @@ void SAL_CALL OStorage::removeEncryption() m_pImpl->AddLog( aException.Message ); m_pImpl->AddLog( ::rtl::OUString( RTL_CONSTASCII_USTRINGPARAM( OSL_LOG_PREFIX "Rethrow" ) ) ); - OSL_ENSURE( sal_False, "The call must not fail, it is pretty simple!" ); + OSL_FAIL( "The call must not fail, it is pretty simple!" ); throw io::IOException( ::rtl::OUString( RTL_CONSTASCII_USTRINGPARAM( OSL_LOG_PREFIX ) ), uno::Reference< uno::XInterface >() ); } } diff --git a/package/source/zippackage/ZipPackage.cxx b/package/source/zippackage/ZipPackage.cxx index 454a4e66094f..e3ab5caabd63 100644 --- a/package/source/zippackage/ZipPackage.cxx +++ b/package/source/zippackage/ZipPackage.cxx @@ -1539,7 +1539,7 @@ void ZipPackage::DisconnectFromTargetAndThrowException_Impl( const uno::Referenc } catch ( uno::Exception& ) { - OSL_ENSURE( sal_False, "These calls are pretty simple, they should not fail!\n" ); + OSL_FAIL( "These calls are pretty simple, they should not fail!\n" ); } ::rtl::OUString aErrTxt( RTL_CONSTASCII_USTRINGPARAM ( OSL_LOG_PREFIX "This package is read only!" ) ); diff --git a/package/source/zippackage/wrapstreamforshare.cxx b/package/source/zippackage/wrapstreamforshare.cxx index 9afb2f8f9428..c39bfa06edbb 100644 --- a/package/source/zippackage/wrapstreamforshare.cxx +++ b/package/source/zippackage/wrapstreamforshare.cxx @@ -44,7 +44,7 @@ WrapStreamForShare::WrapStreamForShare( const uno::Reference< io::XInputStream > m_xSeekable = uno::Reference< io::XSeekable >( m_xInStream, uno::UNO_QUERY ); if ( !m_rMutexRef.Is() || !m_xInStream.is() || !m_xSeekable.is() ) { - OSL_ENSURE( sal_False, "Wrong initialization of wrapping stream!\n" ); + OSL_FAIL( "Wrong initialization of wrapping stream!\n" ); throw uno::RuntimeException( ::rtl::OUString( RTL_CONSTASCII_USTRINGPARAM( OSL_LOG_PREFIX ) ), uno::Reference< uno::XInterface >() ); } } diff --git a/package/source/zippackage/zipfileaccess.cxx b/package/source/zippackage/zipfileaccess.cxx index cb5996aa3c8e..a75bed446335 100644 --- a/package/source/zippackage/zipfileaccess.cxx +++ b/package/source/zippackage/zipfileaccess.cxx @@ -103,7 +103,7 @@ uno::Sequence< ::rtl::OUString > OZipFileAccess::GetPatternsFromString_Impl( con } else { - OSL_ENSURE( sal_False, "The backslash is not guarded!\n" ); + OSL_FAIL( "The backslash is not guarded!\n" ); aPattern[nInd] += ::rtl::OUString::valueOf( (sal_Unicode)'\\' ); } } @@ -281,7 +281,7 @@ uno::Sequence< ::rtl::OUString > SAL_CALL OZipFileAccess::getElementNames() { if ( aNames.getLength() < ++nLen ) { - OSL_ENSURE( sal_False, "The size must be the same!\n" ); + OSL_FAIL( "The size must be the same!\n" ); aNames.realloc( nLen ); } @@ -290,7 +290,7 @@ uno::Sequence< ::rtl::OUString > SAL_CALL OZipFileAccess::getElementNames() if ( aNames.getLength() != nLen ) { - OSL_ENSURE( sal_False, "The size must be the same!\n" ); + OSL_FAIL( "The size must be the same!\n" ); aNames.realloc( nLen ); } |