summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
-rw-r--r--dbaccess/source/core/api/FilteredContainer.cxx2
-rw-r--r--dbaccess/source/core/api/query.cxx2
-rw-r--r--dbaccess/source/core/dataaccess/ContentHelper.cxx10
-rw-r--r--dbaccess/source/core/dataaccess/definitioncontainer.cxx4
-rw-r--r--dbaccess/source/core/dataaccess/documentcontainer.cxx4
-rw-r--r--dbaccess/source/core/dataaccess/documentdefinition.cxx6
-rw-r--r--dbaccess/source/core/misc/ContainerMediator.cxx2
-rw-r--r--dbaccess/source/filter/xml/dbloader2.cxx4
-rw-r--r--dbaccess/source/filter/xml/xmlDataSourceSetting.cxx4
-rw-r--r--dbaccess/source/filter/xml/xmlExport.cxx2
-rw-r--r--dbaccess/source/shared/registrationhelper.cxx4
-rw-r--r--dbaccess/source/ui/app/AppControllerDnD.cxx4
-rw-r--r--dbaccess/source/ui/app/AppDetailPageHelper.cxx2
-rw-r--r--dbaccess/source/ui/browser/brwctrlr.cxx14
-rw-r--r--dbaccess/source/ui/browser/exsrcbrw.cxx11
-rw-r--r--dbaccess/source/ui/browser/genericcontroller.cxx2
-rw-r--r--dbaccess/source/ui/browser/unodatbr.cxx20
-rw-r--r--dbaccess/source/ui/control/FieldDescControl.cxx2
-rw-r--r--dbaccess/source/ui/dlg/DBSetupConnectionPages.cxx2
-rw-r--r--dbaccess/source/ui/dlg/directsql.cxx2
-rw-r--r--dbaccess/source/ui/dlg/indexdialog.cxx2
-rw-r--r--dbaccess/source/ui/dlg/indexfieldscontrol.cxx8
-rw-r--r--dbaccess/source/ui/dlg/odbcconfig.cxx2
-rw-r--r--dbaccess/source/ui/inc/directsql.hxx2
-rw-r--r--dbaccess/source/ui/misc/UITools.cxx5
-rw-r--r--dbaccess/source/ui/misc/WCopyTable.cxx4
-rw-r--r--dbaccess/source/ui/misc/indexcollection.cxx12
-rw-r--r--dbaccess/source/ui/misc/linkeddocuments.cxx2
-rw-r--r--dbaccess/source/ui/querydesign/querycontroller.cxx4
-rw-r--r--dbaccess/source/ui/tabledesign/TEditControl.cxx8
-rw-r--r--dbaccess/source/ui/tabledesign/TableController.cxx14
-rw-r--r--dbaccess/source/ui/uno/unosqlmessage.cxx2
-rw-r--r--reportdesign/source/core/api/ReportDefinition.cxx4
-rw-r--r--reportdesign/source/core/sdr/UndoActions.cxx6
-rw-r--r--reportdesign/source/filter/xml/xmlControlProperty.cxx6
-rw-r--r--reportdesign/source/ui/inspection/DataProviderHandler.cxx4
-rw-r--r--reportdesign/source/ui/inspection/GeometryHandler.cxx6
-rw-r--r--reportdesign/source/ui/misc/RptUndo.cxx4
-rw-r--r--reportdesign/source/ui/misc/UITools.cxx2
-rw-r--r--reportdesign/source/ui/report/propbrw.cxx8
40 files changed, 103 insertions, 105 deletions
diff --git a/dbaccess/source/core/api/FilteredContainer.cxx b/dbaccess/source/core/api/FilteredContainer.cxx
index a3deb6d89171..d9ead8aa4f79 100644
--- a/dbaccess/source/core/api/FilteredContainer.cxx
+++ b/dbaccess/source/core/api/FilteredContainer.cxx
@@ -459,7 +459,7 @@ sal_Int32 createWildCardVector(Sequence< ::rtl::OUString >& _rTableFilter, ::std
switch ( nFilterMode )
{
default:
- OSL_ENSURE( sal_False, "OTableContainer::getAllTableTypeFilter: unknown TableTypeFilterMode!" );
+ OSL_FAIL( "OTableContainer::getAllTableTypeFilter: unknown TableTypeFilterMode!" );
case FILTER_MODE_MIX_ALL:
_rFilter.realloc( 3 );
_rFilter[0] = sView;
diff --git a/dbaccess/source/core/api/query.cxx b/dbaccess/source/core/api/query.cxx
index 04dd9793cddf..ac2201841fbe 100644
--- a/dbaccess/source/core/api/query.cxx
+++ b/dbaccess/source/core/api/query.cxx
@@ -111,7 +111,7 @@ OQuery::OQuery( const Reference< XPropertySet >& _rxCommandDefinition
}
catch(Exception&)
{
- OSL_ENSURE(sal_False, "OQueryDescriptor_Base::OQueryDescriptor_Base: caught an exception!");
+ OSL_FAIL("OQueryDescriptor_Base::OQueryDescriptor_Base: caught an exception!");
}
m_xCommandDefinition->addPropertyChangeListener(::rtl::OUString(), this);
diff --git a/dbaccess/source/core/dataaccess/ContentHelper.cxx b/dbaccess/source/core/dataaccess/ContentHelper.cxx
index 45e778410681..dd3082aa157f 100644
--- a/dbaccess/source/core/dataaccess/ContentHelper.cxx
+++ b/dbaccess/source/core/dataaccess/ContentHelper.cxx
@@ -181,7 +181,7 @@ Any SAL_CALL OContentHelper::execute( const Command& aCommand, sal_Int32 /*Comma
Sequence< Property > Properties;
if ( !( aCommand.Argument >>= Properties ) )
{
- OSL_ENSURE( sal_False, "Wrong argument type!" );
+ OSL_FAIL( "Wrong argument type!" );
ucbhelper::cancelCommandExecution(
makeAny( IllegalArgumentException(
rtl::OUString(),
@@ -201,7 +201,7 @@ Any SAL_CALL OContentHelper::execute( const Command& aCommand, sal_Int32 /*Comma
Sequence< PropertyValue > aProperties;
if ( !( aCommand.Argument >>= aProperties ) )
{
- OSL_ENSURE( sal_False, "Wrong argument type!" );
+ OSL_FAIL( "Wrong argument type!" );
ucbhelper::cancelCommandExecution(
makeAny( IllegalArgumentException(
rtl::OUString(),
@@ -213,7 +213,7 @@ Any SAL_CALL OContentHelper::execute( const Command& aCommand, sal_Int32 /*Comma
if ( !aProperties.getLength() )
{
- OSL_ENSURE( sal_False, "No properties!" );
+ OSL_FAIL( "No properties!" );
ucbhelper::cancelCommandExecution(
makeAny( IllegalArgumentException(
rtl::OUString(),
@@ -242,7 +242,7 @@ Any SAL_CALL OContentHelper::execute( const Command& aCommand, sal_Int32 /*Comma
// Unsupported command
//////////////////////////////////////////////////////////////////
- OSL_ENSURE( sal_False, "Content::execute - unsupported command!" );
+ OSL_FAIL( "Content::execute - unsupported command!" );
ucbhelper::cancelCommandExecution(
makeAny( UnsupportedCommandException(
@@ -407,7 +407,7 @@ Sequence< Any > OContentHelper::setPropertyValues(const Sequence< PropertyValue
}
catch( const Exception& )
{
- OSL_ENSURE( sal_False, "OContentHelper::setPropertyValues('Title'): caught an exception while renaming!" );
+ OSL_FAIL( "OContentHelper::setPropertyValues('Title'): caught an exception while renaming!" );
}
}
else
diff --git a/dbaccess/source/core/dataaccess/definitioncontainer.cxx b/dbaccess/source/core/dataaccess/definitioncontainer.cxx
index 0803ae001f08..f7645349e79d 100644
--- a/dbaccess/source/core/dataaccess/definitioncontainer.cxx
+++ b/dbaccess/source/core/dataaccess/definitioncontainer.cxx
@@ -498,7 +498,7 @@ namespace
}
catch( const Exception& )
{
- OSL_ENSURE( sal_False, "lcl_ensureName: caught an exception while obtaining the current name!" );
+ OSL_FAIL( "lcl_ensureName: caught an exception while obtaining the current name!" );
}
// set the new name
@@ -513,7 +513,7 @@ namespace
}
catch( const Exception& )
{
- OSL_ENSURE( sal_False, "lcl_ensureName: caught an exception!" );
+ OSL_FAIL( "lcl_ensureName: caught an exception!" );
}
return false;
}
diff --git a/dbaccess/source/core/dataaccess/documentcontainer.cxx b/dbaccess/source/core/dataaccess/documentcontainer.cxx
index 7919dbe52b7e..dd2a2928cd77 100644
--- a/dbaccess/source/core/dataaccess/documentcontainer.cxx
+++ b/dbaccess/source/core/dataaccess/documentcontainer.cxx
@@ -421,7 +421,7 @@ Any SAL_CALL ODocumentContainer::execute( const Command& aCommand, sal_Int32 Com
OpenCommandArgument2 aOpenCommand;
if ( !( aCommand.Argument >>= aOpenCommand ) )
{
- OSL_ENSURE( sal_False, "Wrong argument type!" );
+ OSL_FAIL( "Wrong argument type!" );
ucbhelper::cancelCommandExecution(
makeAny( IllegalArgumentException(
rtl::OUString(),
@@ -467,7 +467,7 @@ Any SAL_CALL ODocumentContainer::execute( const Command& aCommand, sal_Int32 Com
InsertCommandArgument arg;
if ( !( aCommand.Argument >>= arg ) )
{
- OSL_ENSURE( sal_False, "Wrong argument type!" );
+ OSL_FAIL( "Wrong argument type!" );
ucbhelper::cancelCommandExecution(
makeAny( IllegalArgumentException(
rtl::OUString(),
diff --git a/dbaccess/source/core/dataaccess/documentdefinition.cxx b/dbaccess/source/core/dataaccess/documentdefinition.cxx
index 7b5baa1d5f8e..49c331b2b572 100644
--- a/dbaccess/source/core/dataaccess/documentdefinition.cxx
+++ b/dbaccess/source/core/dataaccess/documentdefinition.cxx
@@ -1062,7 +1062,7 @@ Any SAL_CALL ODocumentDefinition::execute( const Command& aCommand, sal_Int32 Co
aCommand.Argument >>= aIni;
if ( aIni.getLength() != 2 )
{
- OSL_ENSURE( sal_False, "Wrong argument type!" );
+ OSL_FAIL( "Wrong argument type!" );
ucbhelper::cancelCommandExecution(
makeAny( IllegalArgumentException(
rtl::OUString(),
@@ -1088,7 +1088,7 @@ Any SAL_CALL ODocumentDefinition::execute( const Command& aCommand, sal_Int32 Co
aCommand.Argument >>= aIni;
if ( !aIni.getLength() )
{
- OSL_ENSURE( sal_False, "Wrong argument count!" );
+ OSL_FAIL( "Wrong argument count!" );
ucbhelper::cancelCommandExecution(
makeAny( IllegalArgumentException(
rtl::OUString(),
@@ -1208,7 +1208,7 @@ void ODocumentDefinition::onCommandInsert( const ::rtl::OUString& _sURL, const R
// Check, if all required properties were set.
if ( !_sURL.getLength() || m_xEmbeddedObject.is() )
{
- OSL_ENSURE( sal_False, "Content::onCommandInsert - property value missing!" );
+ OSL_FAIL( "Content::onCommandInsert - property value missing!" );
Sequence< rtl::OUString > aProps( 1 );
aProps[ 0 ] = PROPERTY_URL;
diff --git a/dbaccess/source/core/misc/ContainerMediator.cxx b/dbaccess/source/core/misc/ContainerMediator.cxx
index f8e4b294e659..417d49c9c372 100644
--- a/dbaccess/source/core/misc/ContainerMediator.cxx
+++ b/dbaccess/source/core/misc/ContainerMediator.cxx
@@ -75,7 +75,7 @@ OContainerMediator::OContainerMediator( const Reference< XContainer >& _xContain
}
catch(Exception&)
{
- OSL_ENSURE(sal_False, "OContainerMediator::OContainerMediator: caught an exception!");
+ OSL_FAIL("OContainerMediator::OContainerMediator: caught an exception!");
}
osl_decrementInterlockedCount( &m_refCount );
}
diff --git a/dbaccess/source/filter/xml/dbloader2.cxx b/dbaccess/source/filter/xml/dbloader2.cxx
index 1c7bd7cafadd..11f0b667abd8 100644
--- a/dbaccess/source/filter/xml/dbloader2.cxx
+++ b/dbaccess/source/filter/xml/dbloader2.cxx
@@ -354,7 +354,7 @@ namespace
}
catch( const Exception& )
{
- OSL_ENSURE( sal_False, "lcl_urlAllowsInteraction: caught an exception while analyzing the URL!" );
+ OSL_FAIL( "lcl_urlAllowsInteraction: caught an exception while analyzing the URL!" );
}
return bDoesAllow;
}
@@ -626,7 +626,7 @@ IMPL_LINK( DBContentLoader, OnStartTableWizard, void*, /*NOTINTERESTEDIN*/ )
}
catch(const Exception&)
{
- OSL_ENSURE(sal_False, "caught an exception while starting the table wizard!");
+ OSL_FAIL("caught an exception while starting the table wizard!");
}
m_xMySelf = NULL;
return 0L;
diff --git a/dbaccess/source/filter/xml/xmlDataSourceSetting.cxx b/dbaccess/source/filter/xml/xmlDataSourceSetting.cxx
index 3e2fd3662592..c004e7b62534 100644
--- a/dbaccess/source/filter/xml/xmlDataSourceSetting.cxx
+++ b/dbaccess/source/filter/xml/xmlDataSourceSetting.cxx
@@ -220,7 +220,7 @@ Any OXMLDataSourceSetting::convertString(const ::com::sun::star::uno::Type& _rEx
}
case TypeClass_HYPER:
{
- OSL_ENSURE(sal_False, "OXMLDataSourceSetting::convertString: 64-bit integers not implemented yet!");
+ OSL_FAIL("OXMLDataSourceSetting::convertString: 64-bit integers not implemented yet!");
}
break;
case TypeClass_DOUBLE:
@@ -241,7 +241,7 @@ Any OXMLDataSourceSetting::convertString(const ::com::sun::star::uno::Type& _rEx
aReturn <<= _rReadCharacters;
break;
default:
- OSL_ENSURE(sal_False, "OXMLDataSourceSetting::convertString: invalid type class!");
+ OSL_FAIL("OXMLDataSourceSetting::convertString: invalid type class!");
}
return aReturn;
diff --git a/dbaccess/source/filter/xml/xmlExport.cxx b/dbaccess/source/filter/xml/xmlExport.cxx
index 6ab73c64c360..6ca38bb37f89 100644
--- a/dbaccess/source/filter/xml/xmlExport.cxx
+++ b/dbaccess/source/filter/xml/xmlExport.cxx
@@ -739,7 +739,7 @@ void ODBExport::exportDataSourceSettings()
pSequenceIterator.reset( new OSequenceIterator< Any >( aIter->Value ) );
break;
default:
- OSL_ENSURE(sal_False, "unsupported sequence type !");
+ OSL_FAIL("unsupported sequence type !");
break;
}
if ( pSequenceIterator.get() )
diff --git a/dbaccess/source/shared/registrationhelper.cxx b/dbaccess/source/shared/registrationhelper.cxx
index 9f5d05da122c..69a6879fa508 100644
--- a/dbaccess/source/shared/registrationhelper.cxx
+++ b/dbaccess/source/shared/registrationhelper.cxx
@@ -83,7 +83,7 @@ void OModuleRegistration::revokeComponent(const ::rtl::OUString& _rImplementatio
{
if (!s_pImplementationNames)
{
- OSL_ENSURE(sal_False, "OModuleRegistration::revokeComponent : have no class infos ! Are you sure called this method at the right time ?");
+ OSL_FAIL("OModuleRegistration::revokeComponent : have no class infos ! Are you sure called this method at the right time ?");
return;
}
OSL_ENSURE(s_pImplementationNames && s_pSupportedServices && s_pCreationFunctionPointers && s_pFactoryFunctionPointers,
@@ -126,7 +126,7 @@ uno::Reference< uno::XInterface > OModuleRegistration::getComponentFactory(
if (!s_pImplementationNames)
{
- OSL_ENSURE(sal_False, "OModuleRegistration::getComponentFactory : have no class infos ! Are you sure called this method at the right time ?");
+ OSL_FAIL("OModuleRegistration::getComponentFactory : have no class infos ! Are you sure called this method at the right time ?");
return NULL;
}
OSL_ENSURE(s_pImplementationNames && s_pSupportedServices && s_pCreationFunctionPointers && s_pFactoryFunctionPointers,
diff --git a/dbaccess/source/ui/app/AppControllerDnD.cxx b/dbaccess/source/ui/app/AppControllerDnD.cxx
index e58c11a9ae86..7e8f56972e0f 100644
--- a/dbaccess/source/ui/app/AppControllerDnD.cxx
+++ b/dbaccess/source/ui/app/AppControllerDnD.cxx
@@ -173,7 +173,7 @@ void OApplicationController::deleteTables(const ::std::vector< ::rtl::OUString>&
if(e.TargetException >>= aSql)
aErrorInfo = aSql;
else
- OSL_ENSURE(sal_False, "OApplicationController::implDropTable: something strange happended!");
+ OSL_FAIL("OApplicationController::implDropTable: something strange happended!");
}
catch( const Exception& )
{
@@ -294,7 +294,7 @@ void OApplicationController::deleteObjects( ElementType _eType, const ::std::vec
if ( e.TargetException >>= aSql )
showError( SQLExceptionInfo( e.TargetException ) );
else
- OSL_ENSURE( sal_False, "OApplicationController::deleteObjects: something strange happended!" );
+ OSL_FAIL( "OApplicationController::deleteObjects: something strange happended!" );
}
catch( const Exception& )
{
diff --git a/dbaccess/source/ui/app/AppDetailPageHelper.cxx b/dbaccess/source/ui/app/AppDetailPageHelper.cxx
index de34b955bd36..b10ee6afd78f 100644
--- a/dbaccess/source/ui/app/AppDetailPageHelper.cxx
+++ b/dbaccess/source/ui/app/AppDetailPageHelper.cxx
@@ -653,7 +653,7 @@ void OAppDetailPageHelper::getElementIcons( ElementType _eType, sal_uInt16& _rIm
case E_REPORT: nDatabaseObjectType = DatabaseObject::REPORT; break;
case E_QUERY: nDatabaseObjectType = DatabaseObject::QUERY; break;
default:
- OSL_ENSURE( sal_False, "OAppDetailPageHelper::GetElementIcons: invalid element type!" );
+ OSL_FAIL( "OAppDetailPageHelper::GetElementIcons: invalid element type!" );
return;
}
_rImageId = aImageProvider.getDefaultImageResourceID( nDatabaseObjectType );
diff --git a/dbaccess/source/ui/browser/brwctrlr.cxx b/dbaccess/source/ui/browser/brwctrlr.cxx
index 0a60b4c9a2e9..7b4293318712 100644
--- a/dbaccess/source/ui/browser/brwctrlr.cxx
+++ b/dbaccess/source/ui/browser/brwctrlr.cxx
@@ -504,7 +504,7 @@ Sequence< ::rtl::OUString > SAL_CALL SbaXDataBrowserController::FormControllerIm
//------------------------------------------------------------------
void SAL_CALL SbaXDataBrowserController::FormControllerImpl::setModel(const Reference< ::com::sun::star::awt::XTabControllerModel > & /*Model*/) throw( RuntimeException )
{
- OSL_ENSURE(sal_False, "SbaXDataBrowserController::FormControllerImpl::setModel : invalid call, can't change my model !");
+ OSL_FAIL("SbaXDataBrowserController::FormControllerImpl::setModel : invalid call, can't change my model !");
}
//------------------------------------------------------------------
@@ -516,7 +516,7 @@ Reference< ::com::sun::star::awt::XTabControllerModel > SAL_CALL SbaXDataBrowse
//------------------------------------------------------------------
void SAL_CALL SbaXDataBrowserController::FormControllerImpl::setContainer(const Reference< ::com::sun::star::awt::XControlContainer > & /*_Container*/) throw( RuntimeException )
{
- OSL_ENSURE(sal_False, "SbaXDataBrowserController::FormControllerImpl::setContainer : invalid call, can't change my container !");
+ OSL_FAIL("SbaXDataBrowserController::FormControllerImpl::setContainer : invalid call, can't change my container !");
}
//------------------------------------------------------------------
@@ -541,13 +541,13 @@ Sequence< Reference< ::com::sun::star::awt::XControl > > SAL_CALL SbaXDataBrowse
//------------------------------------------------------------------
void SAL_CALL SbaXDataBrowserController::FormControllerImpl::autoTabOrder(void) throw( RuntimeException )
{
- OSL_ENSURE(sal_False, "SbaXDataBrowserController::FormControllerImpl::autoTabOrder : nothing to do (always have only one control) !");
+ OSL_FAIL("SbaXDataBrowserController::FormControllerImpl::autoTabOrder : nothing to do (always have only one control) !");
}
//------------------------------------------------------------------
void SAL_CALL SbaXDataBrowserController::FormControllerImpl::activateTabOrder(void) throw( RuntimeException )
{
- OSL_ENSURE(sal_False, "SbaXDataBrowserController::FormControllerImpl::activateTabOrder : nothing to do (always have only one control) !");
+ OSL_FAIL("SbaXDataBrowserController::FormControllerImpl::activateTabOrder : nothing to do (always have only one control) !");
}
//------------------------------------------------------------------
@@ -1089,7 +1089,7 @@ void SAL_CALL SbaXDataBrowserController::focusLost(const FocusEvent& e) throw( R
if (xCommitable.is())
xCommitable->commit();
else
- OSL_ENSURE(sal_False, "SbaXDataBrowserController::focusLost : why is my control not commitable ?");
+ OSL_FAIL("SbaXDataBrowserController::focusLost : why is my control not commitable ?");
}
// -------------------------------------------------------------------------
@@ -1785,7 +1785,7 @@ void SbaXDataBrowserController::applyParserOrder(const ::rtl::OUString& _rOldOrd
Reference< XPropertySet > xFormSet(getRowSet(), UNO_QUERY);
if (!m_xLoadable.is())
{
- OSL_ENSURE(sal_False, "SbaXDataBrowserController::applyParserOrder: invalid row set!");
+ OSL_FAIL("SbaXDataBrowserController::applyParserOrder: invalid row set!");
return;
}
@@ -1827,7 +1827,7 @@ void SbaXDataBrowserController::applyParserFilter(const ::rtl::OUString& _rOldFi
Reference< XPropertySet > xFormSet(getRowSet(), UNO_QUERY);
if (!m_xLoadable.is())
{
- OSL_ENSURE(sal_False, "SbaXDataBrowserController::applyParserFilter: invalid row set!");
+ OSL_FAIL("SbaXDataBrowserController::applyParserFilter: invalid row set!");
return;
}
diff --git a/dbaccess/source/ui/browser/exsrcbrw.cxx b/dbaccess/source/ui/browser/exsrcbrw.cxx
index 68053fbbc234..898f78cd3ebe 100644
--- a/dbaccess/source/ui/browser/exsrcbrw.cxx
+++ b/dbaccess/source/ui/browser/exsrcbrw.cxx
@@ -185,11 +185,11 @@ void SAL_CALL SbaExternalSourceBrowser::dispatch(const ::com::sun::star::util::U
aControlProps = *(Sequence< ::com::sun::star::beans::PropertyValue>*)pArguments->Value.getValue();
}
else
- OSL_ENSURE(sal_False, ((ByteString("SbaExternalSourceBrowser::dispatch(AddGridColumn) : unknown argument (") += ByteString((const sal_Unicode*)pArguments->Name, gsl_getSystemTextEncoding()).GetBuffer()) += ") !").GetBuffer());
+ OSL_FAIL(((ByteString("SbaExternalSourceBrowser::dispatch(AddGridColumn) : unknown argument (") += ByteString((const sal_Unicode*)pArguments->Name, gsl_getSystemTextEncoding()).GetBuffer()) += ") !").GetBuffer());
}
if (!sControlType.getLength())
{
- OSL_ENSURE(sal_False, "SbaExternalSourceBrowser::dispatch(AddGridColumn) : missing argument (ColumnType) !");
+ OSL_FAIL("SbaExternalSourceBrowser::dispatch(AddGridColumn) : missing argument (ColumnType) !");
sControlType = ::rtl::OUString(RTL_CONSTASCII_USTRINGPARAM("TextField"));
}
OSL_ENSURE(aControlProps.getLength(), "SbaExternalSourceBrowser::dispatch(AddGridColumn) : missing argument (ColumnProperties) !");
@@ -213,8 +213,7 @@ void SAL_CALL SbaExternalSourceBrowser::dispatch(const ::com::sun::star::util::U
}
catch(Exception&)
{
- OSL_ENSURE(sal_False,
- ( ByteString("SbaExternalSourceBrowser::dispatch : could not set a column property (")
+ OSL_FAIL(( ByteString("SbaExternalSourceBrowser::dispatch : could not set a column property (")
+= ByteString(pControlProps->Name.getStr(), (sal_uInt16)pControlProps->Name.getLength(), RTL_TEXTENCODING_ASCII_US)
+= ByteString(")!")).GetBuffer());
}
@@ -253,7 +252,7 @@ void SAL_CALL SbaExternalSourceBrowser::dispatch(const ::com::sun::star::util::U
}
if (!xMasterForm.is())
{
- OSL_ENSURE(sal_False, "SbaExternalSourceBrowser::dispatch(FormSlots/AttachToForm) : please specify a form to attach to as argument !");
+ OSL_FAIL("SbaExternalSourceBrowser::dispatch(FormSlots/AttachToForm) : please specify a form to attach to as argument !");
return;
}
@@ -425,7 +424,7 @@ void SbaExternalSourceBrowser::Attach(const Reference< XRowSet > & xMaster)
}
catch(Exception&)
{
- OSL_ENSURE(sal_False, "SbaExternalSourceBrowser::Attach : couldn't restore the cursor position !");
+ OSL_FAIL("SbaExternalSourceBrowser::Attach : couldn't restore the cursor position !");
}
}
diff --git a/dbaccess/source/ui/browser/genericcontroller.cxx b/dbaccess/source/ui/browser/genericcontroller.cxx
index f82912466ef1..706d58400c2d 100644
--- a/dbaccess/source/ui/browser/genericcontroller.cxx
+++ b/dbaccess/source/ui/browser/genericcontroller.cxx
@@ -1298,7 +1298,7 @@ namespace
pReturn = "sbasic";
else
{
- OSL_ENSURE( sal_False, "lcl_getModuleHelpModuleName: no installed module found" );
+ OSL_FAIL( "lcl_getModuleHelpModuleName: no installed module found" );
}
}
}
diff --git a/dbaccess/source/ui/browser/unodatbr.cxx b/dbaccess/source/ui/browser/unodatbr.cxx
index 418a1bdef48b..216afb3caf2c 100644
--- a/dbaccess/source/ui/browser/unodatbr.cxx
+++ b/dbaccess/source/ui/browser/unodatbr.cxx
@@ -1351,7 +1351,7 @@ void SbaTableQueryBrowser::connectExternalDispatches()
if ( feature->second.xDispatcher.get() == static_cast< XDispatch* >( this ) )
{
- OSL_ENSURE( sal_False, "SbaTableQueryBrowser::connectExternalDispatches: this should not happen anymore!" );
+ OSL_FAIL( "SbaTableQueryBrowser::connectExternalDispatches: this should not happen anymore!" );
// (nowadays, the URLs aren't in our SupportedFeatures list anymore, so we should
// not supply a dispatcher for this)
feature->second.xDispatcher.clear();
@@ -1500,7 +1500,7 @@ sal_Bool SAL_CALL SbaTableQueryBrowser::select( const Any& _rSelection ) throw (
}
catch(const Exception&)
{
- OSL_ENSURE(sal_False, "SbaTableQueryBrowser::select: could not extract the descriptor!");
+ OSL_FAIL("SbaTableQueryBrowser::select: could not extract the descriptor!");
}
// check the precense of the props we need
@@ -1833,7 +1833,7 @@ FeatureState SbaTableQueryBrowser::GetState(sal_uInt16 nId) const
}
catch(DisposedException&)
{
- OSL_ENSURE(sal_False, "SbaTableQueryBrowser::GetState: object already disposed!");
+ OSL_FAIL("SbaTableQueryBrowser::GetState: object already disposed!");
}
catch( const Exception& )
{
@@ -1856,7 +1856,7 @@ FeatureState SbaTableQueryBrowser::GetState(sal_uInt16 nId) const
case CommandType::COMMAND:
sTitle = String(ModuleRes(STR_QRY_TITLE)); break;
default:
- OSL_ENSURE(sal_False, "SbaTableQueryBrowser::GetState: unknown command type!");
+ OSL_FAIL("SbaTableQueryBrowser::GetState: unknown command type!");
}
::rtl::OUString aName;
xProp->getPropertyValue(PROPERTY_COMMAND) >>= aName;
@@ -2299,7 +2299,7 @@ IMPL_LINK(SbaTableQueryBrowser, OnExpandEntry, SvLBoxEntry*, _pParent)
if(e.TargetException >>= aSql)
aInfo = aSql;
else
- OSL_ENSURE(sal_False, "SbaTableQueryBrowser::OnExpandEntry: something strange happended!");
+ OSL_FAIL("SbaTableQueryBrowser::OnExpandEntry: something strange happended!");
}
catch( const Exception& )
{
@@ -2766,7 +2766,7 @@ bool SbaTableQueryBrowser::implSelect( SvLBoxEntry* _pEntry )
if(e.TargetException >>= aSql)
showError(SQLExceptionInfo(aSql));
else
- OSL_ENSURE(sal_False, "SbaTableQueryBrowser::implSelect: something strange happended!");
+ OSL_FAIL("SbaTableQueryBrowser::implSelect: something strange happended!");
// reset the values
xRowSetProps->setPropertyValue(PROPERTY_DATASOURCENAME,Any());
xRowSetProps->setPropertyValue(PROPERTY_ACTIVE_CONNECTION,Any());
@@ -3105,11 +3105,11 @@ void SbaTableQueryBrowser::unloadAndCleanup( sal_Bool _bDisposeConnection )
if(e.TargetException >>= aSql)
showError(SQLExceptionInfo(aSql));
else
- OSL_ENSURE(sal_False, "SbaTableQueryBrowser::unloadAndCleanup: something strange happended!");
+ OSL_FAIL("SbaTableQueryBrowser::unloadAndCleanup: something strange happended!");
}
catch(Exception&)
{
- OSL_ENSURE(sal_False, "SbaTableQueryBrowser::unloadAndCleanup: could not reset the form");
+ OSL_FAIL("SbaTableQueryBrowser::unloadAndCleanup: could not reset the form");
}
}
@@ -3270,7 +3270,7 @@ void SbaTableQueryBrowser::impl_initialize()
}
catch( const Exception& )
{
- OSL_ENSURE( sal_False, "SbaTableQueryBrowser::impl_initialize: a connection parent which does not have a 'Name'!??" );
+ OSL_FAIL( "SbaTableQueryBrowser::impl_initialize: a connection parent which does not have a 'Name'!??" );
}
}
}
@@ -3307,7 +3307,7 @@ void SbaTableQueryBrowser::impl_initialize()
}
catch(const Exception&)
{
- OSL_ENSURE(sal_False, "SbaTableQueryBrowser::impl_initialize: could not set the update related names!");
+ OSL_FAIL("SbaTableQueryBrowser::impl_initialize: could not set the update related names!");
}
}
diff --git a/dbaccess/source/ui/control/FieldDescControl.cxx b/dbaccess/source/ui/control/FieldDescControl.cxx
index 3e66ab51e027..c30b36782582 100644
--- a/dbaccess/source/ui/control/FieldDescControl.cxx
+++ b/dbaccess/source/ui/control/FieldDescControl.cxx
@@ -1518,7 +1518,7 @@ void OFieldDescControl::DisplayData(OFieldDescription* pFieldDescr )
if( pNumType )
{
- OSL_ENSURE(sal_False, "OFieldDescControl::DisplayData: invalid num type!");
+ OSL_FAIL("OFieldDescControl::DisplayData: invalid num type!");
}
if( pLength )
diff --git a/dbaccess/source/ui/dlg/DBSetupConnectionPages.cxx b/dbaccess/source/ui/dlg/DBSetupConnectionPages.cxx
index 83506495c575..d2b4bb956b67 100644
--- a/dbaccess/source/ui/dlg/DBSetupConnectionPages.cxx
+++ b/dbaccess/source/ui/dlg/DBSetupConnectionPages.cxx
@@ -335,7 +335,7 @@ DBG_NAME(OMySQLIntroPageSetup)
// -----------------------------------------------------------------------
sal_Bool OMySQLIntroPageSetup::FillItemSet(SfxItemSet& /*_rSet*/)
{
- OSL_ENSURE(sal_False,"Who called me?! Please ask oj for more information.");
+ OSL_FAIL("Who called me?! Please ask oj for more information.");
return sal_True;
}
diff --git a/dbaccess/source/ui/dlg/directsql.cxx b/dbaccess/source/ui/dlg/directsql.cxx
index 99692ffc2961..0e4a61414de8 100644
--- a/dbaccess/source/ui/dlg/directsql.cxx
+++ b/dbaccess/source/ui/dlg/directsql.cxx
@@ -308,7 +308,7 @@ DBG_NAME(DirectSQLDialog)
m_aSQL.SetSelection(Selection(sStatement.Len(), sStatement.Len()));
}
else
- OSL_ENSURE(sal_False, "DirectSQLDialog::switchToHistory: invalid position!");
+ OSL_FAIL("DirectSQLDialog::switchToHistory: invalid position!");
}
//--------------------------------------------------------------------
diff --git a/dbaccess/source/ui/dlg/indexdialog.cxx b/dbaccess/source/ui/dlg/indexdialog.cxx
index 1b48dab42801..d4480c464d59 100644
--- a/dbaccess/source/ui/dlg/indexdialog.cxx
+++ b/dbaccess/source/ui/dlg/indexdialog.cxx
@@ -230,7 +230,7 @@ DBG_NAME(DbaIndexDialog)
}
catch(Exception&)
{
- OSL_ENSURE(sal_False, "DbaIndexDialog::DbaIndexDialog: could not retrieve basic information from the UNO collection!");
+ OSL_FAIL("DbaIndexDialog::DbaIndexDialog: could not retrieve basic information from the UNO collection!");
}
fillIndexList();
diff --git a/dbaccess/source/ui/dlg/indexfieldscontrol.cxx b/dbaccess/source/ui/dlg/indexfieldscontrol.cxx
index 927e62c7ddf8..2a85b1a5d58b 100644
--- a/dbaccess/source/ui/dlg/indexfieldscontrol.cxx
+++ b/dbaccess/source/ui/dlg/indexfieldscontrol.cxx
@@ -310,7 +310,7 @@ DBG_NAME(IndexFieldsControl)
break;
default:
- OSL_ENSURE(sal_False, "IndexFieldsControl::GetController: invalid column id!");
+ OSL_FAIL("IndexFieldsControl::GetController: invalid column id!");
}
if (pReturn)
@@ -400,7 +400,7 @@ DBG_NAME(IndexFieldsControl)
}
break;
default:
- OSL_ENSURE(sal_False, "IndexFieldsControl::SaveModified: invalid column id!");
+ OSL_FAIL("IndexFieldsControl::SaveModified: invalid column id!");
}
return sal_True;
}
@@ -424,7 +424,7 @@ DBG_NAME(IndexFieldsControl)
break;
default:
- OSL_ENSURE(sal_False, "IndexFieldsControl::InitController: invalid column id!");
+ OSL_FAIL("IndexFieldsControl::InitController: invalid column id!");
}
}
@@ -490,7 +490,7 @@ DBG_NAME(IndexFieldsControl)
else
return _rRow->bSortAscending ? m_sAscendingText : m_sDescendingText;
default:
- OSL_ENSURE(sal_False, "IndexFieldsControl::GetCurrentRowCellText: invalid column id!");
+ OSL_FAIL("IndexFieldsControl::GetCurrentRowCellText: invalid column id!");
}
}
return String();
diff --git a/dbaccess/source/ui/dlg/odbcconfig.cxx b/dbaccess/source/ui/dlg/odbcconfig.cxx
index baf20415e4d6..22d68052aee0 100644
--- a/dbaccess/source/ui/dlg/odbcconfig.cxx
+++ b/dbaccess/source/ui/dlg/odbcconfig.cxx
@@ -292,7 +292,7 @@ void OOdbcEnumeration::getDatasourceNames(StringBag& _rNames)
if (!allocEnv())
{
- OSL_ENSURE(sal_False, "OOdbcEnumeration::getDatasourceNames: could not allocate an ODBC environment!");
+ OSL_FAIL("OOdbcEnumeration::getDatasourceNames: could not allocate an ODBC environment!");
return;
}
diff --git a/dbaccess/source/ui/inc/directsql.hxx b/dbaccess/source/ui/inc/directsql.hxx
index dcb9ec5f96c1..250c667166be 100644
--- a/dbaccess/source/ui/inc/directsql.hxx
+++ b/dbaccess/source/ui/inc/directsql.hxx
@@ -126,7 +126,7 @@ namespace dbaui
{ \
const sal_Char* pError = impl_CheckInvariants(); \
if (pError) \
- OSL_ENSURE(sal_False, (ByteString(methodname) += ByteString(": ") += ByteString(pError)).GetBuffer()); \
+ OSL_FAIL((ByteString(methodname) += ByteString(": ") += ByteString(pError)).GetBuffer()); \
}
#else
#define CHECK_INVARIANTS(methodname)
diff --git a/dbaccess/source/ui/misc/UITools.cxx b/dbaccess/source/ui/misc/UITools.cxx
index 8f76cfeec73b..a89699c002a3 100644
--- a/dbaccess/source/ui/misc/UITools.cxx
+++ b/dbaccess/source/ui/misc/UITools.cxx
@@ -210,7 +210,7 @@ SQLExceptionInfo createConnection( const Reference< ::com::sun::star::beans::XP
Reference< XInteractionHandler > xHandler(_rMF->createInstance(SERVICE_TASK_INTERACTION_HANDLER), UNO_QUERY);
if (!xHandler.is())
{
- OSL_ENSURE(sal_False, "createConnection: could not instantiate an interaction handler!");
+ OSL_FAIL("createConnection: could not instantiate an interaction handler!");
// TODO: a real parent!
}
else
@@ -400,8 +400,7 @@ TOTypeInfoSP getTypeInfoFromType(const OTypeInfoMap& _rTypeInfo,
&& ( (_bAutoIncrement && aIter->second->bAutoIncrement) || !_bAutoIncrement )
)
{
- OSL_ENSURE(sal_False,
- ( ::rtl::OString("getTypeInfoFromType: assuming column type ")
+ OSL_FAIL(( ::rtl::OString("getTypeInfoFromType: assuming column type ")
+= ::rtl::OString(aIter->second->aTypeName.getStr(), aIter->second->aTypeName.getLength(), gsl_getSystemTextEncoding())
+= ::rtl::OString("\" (expected type name ")
+= ::rtl::OString(_sTypeName.getStr(), _sTypeName.getLength(), gsl_getSystemTextEncoding())
diff --git a/dbaccess/source/ui/misc/WCopyTable.cxx b/dbaccess/source/ui/misc/WCopyTable.cxx
index 600fb72c68be..ceb8f6d6745e 100644
--- a/dbaccess/source/ui/misc/WCopyTable.cxx
+++ b/dbaccess/source/ui/misc/WCopyTable.cxx
@@ -974,7 +974,7 @@ IMPL_LINK( OCopyTableWizard, ImplOKHdl, OKButton*, EMPTYARG )
break;
default:
{
- OSL_ENSURE(sal_False, "OCopyTableWizard::ImplOKHdl: invalid creation style!");
+ OSL_FAIL("OCopyTableWizard::ImplOKHdl: invalid creation style!");
}
}
@@ -1229,7 +1229,7 @@ void OCopyTableWizard::appendColumns( Reference<XColumnsSupplier>& _rxColSup, co
}
else
{
- OSL_ENSURE(sal_False, "OCopyTableWizard::appendColumns: invalid field name!");
+ OSL_FAIL("OCopyTableWizard::appendColumns: invalid field name!");
}
}
diff --git a/dbaccess/source/ui/misc/indexcollection.cxx b/dbaccess/source/ui/misc/indexcollection.cxx
index 318856ba2345..ae68cd988f55 100644
--- a/dbaccess/source/ui/misc/indexcollection.cxx
+++ b/dbaccess/source/ui/misc/indexcollection.cxx
@@ -157,7 +157,7 @@ namespace dbaui
Reference< XAppend > xAppendIndex(xIndexFactory, UNO_QUERY);
if (!xAppendIndex.is())
{
- OSL_ENSURE(sal_False, "OIndexCollection::commitNewIndex: missing an interface of the index container!");
+ OSL_FAIL("OIndexCollection::commitNewIndex: missing an interface of the index container!");
return;
}
@@ -171,7 +171,7 @@ namespace dbaui
Reference< XAppend > xAppendCols(xColumnFactory, UNO_QUERY);
if (!xAppendCols.is())
{
- OSL_ENSURE(sal_False, "OIndexCollection::commitNewIndex: invalid index descriptor returned!");
+ OSL_FAIL("OIndexCollection::commitNewIndex: invalid index descriptor returned!");
return;
}
@@ -226,7 +226,7 @@ namespace dbaui
Reference< XDrop > xDropIndex(m_xIndexes, UNO_QUERY);
if (!xDropIndex.is())
{
- OSL_ENSURE(sal_False, "OIndexCollection::drop: no XDrop interface!");
+ OSL_FAIL("OIndexCollection::drop: no XDrop interface!");
return sal_False;
}
@@ -273,7 +273,7 @@ namespace dbaui
m_xIndexes->getByName(_rIndex.getOriginalName()) >>= xIndex;
if (!xIndex.is())
{
- OSL_ENSURE(sal_False, "OIndexCollection::implFillIndexInfo: got an invalid index object!");
+ OSL_FAIL("OIndexCollection::implFillIndexInfo: got an invalid index object!");
}
else
implFillIndexInfo(_rIndex, xIndex);
@@ -314,7 +314,7 @@ namespace dbaui
xCols->getByName(*pFieldNames) >>= xIndexColumn;
if (!xIndexColumn.is())
{
- OSL_ENSURE(sal_False, "OIndexCollection::implFillIndexInfo: invalid index column!");
+ OSL_FAIL("OIndexCollection::implFillIndexInfo: invalid index column!");
--aCopyTo;
continue;
}
@@ -383,7 +383,7 @@ namespace dbaui
m_xIndexes->getByName(*pNames) >>= xIndex;
if (!xIndex.is())
{
- OSL_ENSURE(sal_False, "OIndexCollection::implConstructFrom: got an invalid index object ... ignoring!");
+ OSL_FAIL("OIndexCollection::implConstructFrom: got an invalid index object ... ignoring!");
continue;
}
diff --git a/dbaccess/source/ui/misc/linkeddocuments.cxx b/dbaccess/source/ui/misc/linkeddocuments.cxx
index 2207bbb541ad..2de49e7522d8 100644
--- a/dbaccess/source/ui/misc/linkeddocuments.cxx
+++ b/dbaccess/source/ui/misc/linkeddocuments.cxx
@@ -287,7 +287,7 @@ namespace dbaui
break;
default:
- OSL_ENSURE( sal_False, "OLinkedDocumentsAccess::newDocument: please use newFormWithPilot!" );
+ OSL_FAIL( "OLinkedDocumentsAccess::newDocument: please use newFormWithPilot!" );
return Reference< XComponent >();
}
diff --git a/dbaccess/source/ui/querydesign/querycontroller.cxx b/dbaccess/source/ui/querydesign/querycontroller.cxx
index 52fa237d061d..7324b0ab597f 100644
--- a/dbaccess/source/ui/querydesign/querycontroller.cxx
+++ b/dbaccess/source/ui/querydesign/querycontroller.cxx
@@ -727,7 +727,7 @@ void OQueryController::Execute(sal_uInt16 _nId, const Sequence< PropertyValue >&
}
catch( const Exception& )
{
- OSL_ENSURE( sal_False, "OQueryController::Execute(SID_DB_QUERY_PREVIEW): *nobody* is expected to veto closing the preview frame!" );
+ OSL_FAIL( "OQueryController::Execute(SID_DB_QUERY_PREVIEW): *nobody* is expected to veto closing the preview frame!" );
}
}
else
@@ -1697,7 +1697,7 @@ void OQueryController::impl_reset( const bool i_bForceCurrentControllerSettings
}
catch( const Exception& )
{
- OSL_ENSURE( sal_False, "OQueryController::impl_reset: could not retrieve the layout information from the query!" );
+ OSL_FAIL( "OQueryController::impl_reset: could not retrieve the layout information from the query!" );
}
}
}
diff --git a/dbaccess/source/ui/tabledesign/TEditControl.cxx b/dbaccess/source/ui/tabledesign/TEditControl.cxx
index d6e0c2703fa9..6884feaf2ef4 100644
--- a/dbaccess/source/ui/tabledesign/TEditControl.cxx
+++ b/dbaccess/source/ui/tabledesign/TEditControl.cxx
@@ -1122,7 +1122,7 @@ void OTableEditorCtrl::SetCellData( long nRow, sal_uInt16 nColId, const TOTypeIn
SwitchType( _pTypeInfo );
break;
default:
- OSL_ENSURE(sal_False, "OTableEditorCtrl::SetCellData: invalid column!");
+ OSL_FAIL("OTableEditorCtrl::SetCellData: invalid column!");
}
SetControlText(nRow,nColId,_pTypeInfo.get() ? _pTypeInfo->aUIName : ::rtl::OUString());
}
@@ -1149,7 +1149,7 @@ void OTableEditorCtrl::SetCellData( long nRow, sal_uInt16 nColId, const ::com::s
break;
case FIELD_TYPE:
- OSL_ENSURE(sal_False, "OTableEditorCtrl::SetCellData: invalid column!");
+ OSL_FAIL("OTableEditorCtrl::SetCellData: invalid column!");
break;
case COLUMN_DESCRIPTION:
@@ -1177,7 +1177,7 @@ void OTableEditorCtrl::SetCellData( long nRow, sal_uInt16 nColId, const ::com::s
break;
case FIELD_PROPERTY_NUMTYPE:
- OSL_ENSURE(sal_False, "OTableEditorCtrl::SetCellData: invalid column!");
+ OSL_FAIL("OTableEditorCtrl::SetCellData: invalid column!");
break;
case FIELD_PROPERTY_AUTOINC:
@@ -1260,7 +1260,7 @@ Any OTableEditorCtrl::GetCellData( long nRow, sal_uInt16 nColId )
break;
case FIELD_PROPERTY_NUMTYPE:
- OSL_ENSURE(sal_False, "OTableEditorCtrl::GetCellData: invalid column!");
+ OSL_FAIL("OTableEditorCtrl::GetCellData: invalid column!");
break;
case FIELD_PROPERTY_AUTOINC:
diff --git a/dbaccess/source/ui/tabledesign/TableController.cxx b/dbaccess/source/ui/tabledesign/TableController.cxx
index 28450226eb81..b79eba4f8378 100644
--- a/dbaccess/source/ui/tabledesign/TableController.cxx
+++ b/dbaccess/source/ui/tabledesign/TableController.cxx
@@ -368,7 +368,7 @@ sal_Bool OTableController::doSaveDoc(sal_Bool _bSaveAs)
}
catch(Exception&)
{
- OSL_ENSURE(sal_False, "OTableController::doSaveDoc: nothing is expected to happen here!");
+ OSL_FAIL("OTableController::doSaveDoc: nothing is expected to happen here!");
}
sal_Bool bAlter = sal_False;
@@ -505,7 +505,7 @@ void OTableController::doEditIndexes()
OSL_ENSURE(xIndexes.is(), "OTableController::doEditIndexes: no keys got from the indexes supplier!");
}
else
- OSL_ENSURE(sal_False, "OTableController::doEditIndexes: should never have reached this (no indexes supplier)!");
+ OSL_FAIL("OTableController::doEditIndexes: should never have reached this (no indexes supplier)!");
// get the field names
Reference< XColumnsSupplier > xColSupp(m_xTable, UNO_QUERY);
@@ -629,7 +629,7 @@ sal_Bool SAL_CALL OTableController::suspend(sal_Bool /*_bSuspend*/) throw( Runti
}
catch(const Exception&)
{
- OSL_ENSURE(sal_False, "OTableController::suspend: nothing is expected to happen here!");
+ OSL_FAIL("OTableController::suspend: nothing is expected to happen here!");
}
}
@@ -763,7 +763,7 @@ void OTableController::appendColumns(Reference<XColumnsSupplier>& _rxColSup,sal_
}
else
{
- OSL_ENSURE(sal_False, "OTableController::appendColumns: invalid field name!");
+ OSL_FAIL("OTableController::appendColumns: invalid field name!");
}
}
@@ -1089,7 +1089,7 @@ void OTableController::alterColumns()
try { xColumn->getPropertyValue(PROPERTY_TYPENAME) >>= sTypeName; }
catch( const Exception& )
{
- OSL_ENSURE( sal_False, "no TypeName property?!" );
+ OSL_FAIL( "no TypeName property?!" );
// since this is a last minute fix for #i41785#, I want to be on the safe side,
// and catch errors here as early as possible (instead of the whole process of altering
// the columns failing)
@@ -1172,7 +1172,7 @@ void OTableController::alterColumns()
}
else
{
- OSL_ENSURE(sal_False, "OTableController::alterColumns: invalid column (2)!");
+ OSL_FAIL("OTableController::alterColumns: invalid column (2)!");
}
}
catch(const SQLException&)
@@ -1308,7 +1308,7 @@ void OTableController::alterColumns()
}
else
{
- OSL_ENSURE(sal_False, "OTableController::alterColumns: invalid column!");
+ OSL_FAIL("OTableController::alterColumns: invalid column!");
}
}
}
diff --git a/dbaccess/source/ui/uno/unosqlmessage.cxx b/dbaccess/source/ui/uno/unosqlmessage.cxx
index 978468a8acd5..66d65552b264 100644
--- a/dbaccess/source/ui/uno/unosqlmessage.cxx
+++ b/dbaccess/source/ui/uno/unosqlmessage.cxx
@@ -155,7 +155,7 @@ Dialog* OSQLMessageDialog::createDialog(Window* _pParent)
if ( m_aException.hasValue() )
return new OSQLMessageBox( _pParent, SQLExceptionInfo( m_aException ), WB_OK | WB_DEF_OK, m_sHelpURL );
- OSL_ENSURE(sal_False, "OSQLMessageDialog::createDialog : You should use the SQLException property to specify the error to display!");
+ OSL_FAIL("OSQLMessageDialog::createDialog : You should use the SQLException property to specify the error to display!");
return new OSQLMessageBox(_pParent, SQLException());
}
diff --git a/reportdesign/source/core/api/ReportDefinition.cxx b/reportdesign/source/core/api/ReportDefinition.cxx
index acc109abc555..935250b9370b 100644
--- a/reportdesign/source/core/api/ReportDefinition.cxx
+++ b/reportdesign/source/core/api/ReportDefinition.cxx
@@ -243,7 +243,7 @@ void lcl_extractAndStartStatusIndicator( const ::comphelper::MediaDescriptor& _r
}
catch( const uno::Exception& )
{
- OSL_ENSURE( sal_False, "lcl_extractAndStartStatusIndicator: caught an exception!" );
+ OSL_FAIL( "lcl_extractAndStartStatusIndicator: caught an exception!" );
}
}
// -----------------------------------------------------------------------------
@@ -1260,7 +1260,7 @@ void SAL_CALL OReportDefinition::close( ::sal_Bool _bDeliverOwnership ) throw (u
catch( const util::CloseVetoException& ) { throw; }
catch( const uno::Exception& )
{
- OSL_ENSURE( sal_False, "ODatabaseDocument::impl_closeControllerFrames: caught an unexpected exception!" );
+ OSL_FAIL( "ODatabaseDocument::impl_closeControllerFrames: caught an unexpected exception!" );
}
}
}
diff --git a/reportdesign/source/core/sdr/UndoActions.cxx b/reportdesign/source/core/sdr/UndoActions.cxx
index cd4b140873b2..9c7895d6d708 100644
--- a/reportdesign/source/core/sdr/UndoActions.cxx
+++ b/reportdesign/source/core/sdr/UndoActions.cxx
@@ -230,7 +230,7 @@ void OUndoContainerAction::Undo()
}
catch( const Exception& )
{
- OSL_ENSURE( sal_False, "OUndoContainerAction::Undo: caught an exception!" );
+ OSL_FAIL( "OUndoContainerAction::Undo: caught an exception!" );
}
}
}
@@ -258,7 +258,7 @@ void OUndoContainerAction::Redo()
}
catch( const Exception& )
{
- OSL_ENSURE( sal_False, "OUndoContainerAction::Redo: caught an exception!" );
+ OSL_FAIL( "OUndoContainerAction::Redo: caught an exception!" );
}
}
}
@@ -397,7 +397,7 @@ void ORptUndoPropertyAction::setProperty(sal_Bool _bOld)
}
catch( const Exception& )
{
- OSL_ENSURE( sal_False, "ORptUndoPropertyAction::Redo: caught an exception!" );
+ OSL_FAIL( "ORptUndoPropertyAction::Redo: caught an exception!" );
}
}
}
diff --git a/reportdesign/source/filter/xml/xmlControlProperty.cxx b/reportdesign/source/filter/xml/xmlControlProperty.cxx
index 89fe02a0336a..1de438f425ea 100644
--- a/reportdesign/source/filter/xml/xmlControlProperty.cxx
+++ b/reportdesign/source/filter/xml/xmlControlProperty.cxx
@@ -237,7 +237,7 @@ Any OXMLControlProperty::convertString(const ::com::sun::star::uno::Type& _rExpe
}
case TypeClass_HYPER:
{
- OSL_ENSURE(sal_False, "OXMLControlProperty::convertString: 64-bit integers not implemented yet!");
+ OSL_FAIL("OXMLControlProperty::convertString: 64-bit integers not implemented yet!");
}
break;
case TypeClass_DOUBLE:
@@ -321,11 +321,11 @@ Any OXMLControlProperty::convertString(const ::com::sun::star::uno::Type& _rExpe
}
}
else
- OSL_ENSURE(sal_False, "OPropertyImport::convertString: unsupported property type!");
+ OSL_FAIL("OPropertyImport::convertString: unsupported property type!");
}
break;
default:
- OSL_ENSURE(sal_False, "OXMLControlProperty::convertString: invalid type class!");
+ OSL_FAIL("OXMLControlProperty::convertString: invalid type class!");
}
return aReturn;
diff --git a/reportdesign/source/ui/inspection/DataProviderHandler.cxx b/reportdesign/source/ui/inspection/DataProviderHandler.cxx
index 8c991d7d408c..fadd0fd065cc 100644
--- a/reportdesign/source/ui/inspection/DataProviderHandler.cxx
+++ b/reportdesign/source/ui/inspection/DataProviderHandler.cxx
@@ -323,7 +323,7 @@ uno::Any SAL_CALL DataProviderHandler::convertToPropertyValue(const ::rtl::OUStr
}
catch( const uno::Exception& )
{
- OSL_ENSURE( sal_False, "DataProviderHandler::convertToPropertyValue: caught an exception while converting via TypeConverter!" );
+ OSL_FAIL( "DataProviderHandler::convertToPropertyValue: caught an exception while converting via TypeConverter!" );
}
break;
case PROPERTY_ID_MASTERFIELDS:
@@ -357,7 +357,7 @@ uno::Any SAL_CALL DataProviderHandler::convertToControlValue(const ::rtl::OUStri
}
catch( const uno::Exception& )
{
- OSL_ENSURE( sal_False, "GeometryHandler::convertToPropertyValue: caught an exception while converting via TypeConverter!" );
+ OSL_FAIL( "GeometryHandler::convertToPropertyValue: caught an exception while converting via TypeConverter!" );
}
break;
default:
diff --git a/reportdesign/source/ui/inspection/GeometryHandler.cxx b/reportdesign/source/ui/inspection/GeometryHandler.cxx
index b60bfa7a55df..8b7cae395c33 100644
--- a/reportdesign/source/ui/inspection/GeometryHandler.cxx
+++ b/reportdesign/source/ui/inspection/GeometryHandler.cxx
@@ -1022,7 +1022,7 @@ uno::Any SAL_CALL GeometryHandler::convertToPropertyValue(const ::rtl::OUString
}
catch( const uno::Exception& )
{
- OSL_ENSURE( sal_False, "GeometryHandler::convertToPropertyValue: caught an exception while converting via TypeConverter!" );
+ OSL_FAIL( "GeometryHandler::convertToPropertyValue: caught an exception while converting via TypeConverter!" );
}
}
}
@@ -1167,7 +1167,7 @@ uno::Any SAL_CALL GeometryHandler::convertToControlValue(const ::rtl::OUString &
}
catch( const uno::Exception& )
{
- OSL_ENSURE( sal_False, "GeometryHandler::convertToControlValue: caught an exception while converting via TypeConverter!" );
+ OSL_FAIL( "GeometryHandler::convertToControlValue: caught an exception while converting via TypeConverter!" );
}
}
break;
@@ -1609,7 +1609,7 @@ bool GeometryHandler::impl_dialogFilter_nothrow( ::rtl::OUString& _out_rSelected
catch (sdbc::SQLException& e) { aErrorInfo = e; }
catch( const uno::Exception& )
{
- OSL_ENSURE( sal_False, "GeometryHandler::impl_dialogFilter_nothrow: caught an exception!" );
+ OSL_FAIL( "GeometryHandler::impl_dialogFilter_nothrow: caught an exception!" );
}
if ( aErrorInfo.isValid() )
diff --git a/reportdesign/source/ui/misc/RptUndo.cxx b/reportdesign/source/ui/misc/RptUndo.cxx
index 3be1eadc1344..9e1fb6c66861 100644
--- a/reportdesign/source/ui/misc/RptUndo.cxx
+++ b/reportdesign/source/ui/misc/RptUndo.cxx
@@ -203,7 +203,7 @@ void OSectionUndo::Undo()
}
catch( const Exception& )
{
- OSL_ENSURE( sal_False, "OSectionUndo::Undo: caught an exception!" );
+ OSL_FAIL( "OSectionUndo::Undo: caught an exception!" );
}
}
//----------------------------------------------------------------------------
@@ -224,7 +224,7 @@ void OSectionUndo::Redo()
}
catch( const Exception& )
{
- OSL_ENSURE( sal_False, "OSectionUndo::Redo: caught an exception!" );
+ OSL_FAIL( "OSectionUndo::Redo: caught an exception!" );
}
}
//----------------------------------------------------------------------------
diff --git a/reportdesign/source/ui/misc/UITools.cxx b/reportdesign/source/ui/misc/UITools.cxx
index d3ef4c175980..a8dcd7ee351b 100644
--- a/reportdesign/source/ui/misc/UITools.cxx
+++ b/reportdesign/source/ui/misc/UITools.cxx
@@ -1060,7 +1060,7 @@ bool openDialogFormula_nothrow( ::rtl::OUString& _in_out_rFormula
catch (sdbc::SQLException& e) { aErrorInfo = e; }
catch( const uno::Exception& )
{
- OSL_ENSURE( sal_False, "GeometryHandler::impl_dialogFilter_nothrow: caught an exception!" );
+ OSL_FAIL( "GeometryHandler::impl_dialogFilter_nothrow: caught an exception!" );
}
if ( aErrorInfo.isValid() )
diff --git a/reportdesign/source/ui/report/propbrw.cxx b/reportdesign/source/ui/report/propbrw.cxx
index c6154775e7b2..1d5564cace0d 100644
--- a/reportdesign/source/ui/report/propbrw.cxx
+++ b/reportdesign/source/ui/report/propbrw.cxx
@@ -269,7 +269,7 @@ void PropBrw::implDetachController()
}
catch( const Exception& )
{
- OSL_ENSURE( sal_False, "PropBrw::getCurrentPage: caught an exception while retrieving the current page!" );
+ OSL_FAIL( "PropBrw::getCurrentPage: caught an exception while retrieving the current page!" );
}
return sCurrentPage;
}
@@ -289,7 +289,7 @@ sal_Bool PropBrw::Close()
}
catch( const Exception& )
{
- OSL_ENSURE( sal_False, "FmPropBrw::Close: caught an exception while asking the controller!" );
+ OSL_FAIL( "FmPropBrw::Close: caught an exception while asking the controller!" );
}
}
implDetachController();
@@ -346,7 +346,7 @@ void PropBrw::implSetNewObject( const uno::Sequence< Reference<uno::XInterface>
}
catch( const Exception& )
{
- OSL_ENSURE( sal_False, "FmPropBrw::StateChanged: caught an exception while setting the initial page!" );
+ OSL_FAIL( "FmPropBrw::StateChanged: caught an exception while setting the initial page!" );
}
}
SetText( GetHeadlineName(_aObjects) );
@@ -519,7 +519,7 @@ void PropBrw::Update( OSectionView* pNewView )
}
catch( const Exception& )
{
- OSL_ENSURE( sal_False, "FmPropBrw::StateChanged: caught an exception while setting the initial page!" );
+ OSL_FAIL( "FmPropBrw::StateChanged: caught an exception while setting the initial page!" );
}
}
}