diff options
author | Thomas Arnhold <thomas@arnhold.org> | 2011-03-12 14:27:45 +0100 |
---|---|---|
committer | Thomas Arnhold <thomas@arnhold.org> | 2011-03-13 16:50:43 +0100 |
commit | 1848de2f4cce84862cf0843e15f38ce5d1f26108 (patch) | |
tree | 38d3983e56f5d2c900c24750e0050556435cfd6b /scripting | |
parent | e4d0bb122a93d243067814b9d43f9c9ab1e4df65 (diff) |
Move OSL_ENSURE(false,...) to OSL_FAIL(...)
Diffstat (limited to 'scripting')
-rw-r--r-- | scripting/source/inc/util/MiscUtils.hxx | 4 | ||||
-rw-r--r-- | scripting/source/provider/BrowseNodeFactoryImpl.cxx | 2 | ||||
-rw-r--r-- | scripting/source/provider/URIHelper.cxx | 6 | ||||
-rw-r--r-- | scripting/source/stringresource/stringresource.cxx | 10 |
4 files changed, 10 insertions, 12 deletions
diff --git a/scripting/source/inc/util/MiscUtils.hxx b/scripting/source/inc/util/MiscUtils.hxx index 149f46e8d53c..50d693302589 100644 --- a/scripting/source/inc/util/MiscUtils.hxx +++ b/scripting/source/inc/util/MiscUtils.hxx @@ -115,11 +115,11 @@ public: } catch ( css::lang::IllegalArgumentException const & ) { - OSL_ENSURE( false, "Invalid document model!" ); + OSL_FAIL( "Invalid document model!" ); } } - OSL_ENSURE( false, "Unable to obtain URL for document model!" ); + OSL_FAIL( "Unable to obtain URL for document model!" ); return rtl::OUString(); } static css::uno::Reference< css::frame::XModel > tDocUrlToModel( const ::rtl::OUString& url ) diff --git a/scripting/source/provider/BrowseNodeFactoryImpl.cxx b/scripting/source/provider/BrowseNodeFactoryImpl.cxx index 434e7d962eb4..135410b37c9a 100644 --- a/scripting/source/provider/BrowseNodeFactoryImpl.cxx +++ b/scripting/source/provider/BrowseNodeFactoryImpl.cxx @@ -418,7 +418,7 @@ public: } catch( uno::Exception& ) { - OSL_ENSURE( false, "DefaultBrowseNode::DefaultBrowseNode: Caught exception!" ); + OSL_FAIL( "DefaultBrowseNode::DefaultBrowseNode: Caught exception!" ); } OSL_ENSURE( m_xAggProxy.is(), "DefaultBrowseNode::DefaultBrowseNode: Wrapped BrowseNode cannot be aggregated!" ); diff --git a/scripting/source/provider/URIHelper.cxx b/scripting/source/provider/URIHelper.cxx index e5ab80f838cf..d114ea963dcf 100644 --- a/scripting/source/provider/URIHelper.cxx +++ b/scripting/source/provider/URIHelper.cxx @@ -78,8 +78,7 @@ ScriptingFrameworkURIHelper::ScriptingFrameworkURIHelper( } catch (uno::Exception&) { - OSL_ENSURE(false, - "Scripting Framework error initialising XSimpleFileAccess"); + OSL_FAIL("Scripting Framework error initialising XSimpleFileAccess"); } try @@ -92,8 +91,7 @@ ScriptingFrameworkURIHelper::ScriptingFrameworkURIHelper( } catch (uno::Exception&) { - OSL_ENSURE(false, - "Scripting Framework error initialising XUriReferenceFactory"); + OSL_FAIL("Scripting Framework error initialising XUriReferenceFactory"); } } diff --git a/scripting/source/stringresource/stringresource.cxx b/scripting/source/stringresource/stringresource.cxx index cf04f09e3ec5..1d83e6292867 100644 --- a/scripting/source/stringresource/stringresource.cxx +++ b/scripting/source/stringresource/stringresource.cxx @@ -1558,7 +1558,7 @@ Reference< io::XInputStream > BinaryInput::getInputStreamForSection( sal_Int32 n } } else - OSL_ENSURE( false, "BinaryInput::getInputStreamForSection(): Read past end" ); + OSL_FAIL( "BinaryInput::getInputStreamForSection(): Read past end" ); return xIn; } @@ -1568,7 +1568,7 @@ void BinaryInput::seek( sal_Int32 nPos ) if( nPos <= m_nSize ) m_nCurPos = nPos; else - OSL_ENSURE( false, "BinaryInput::seek(): Position past end" ); + OSL_FAIL( "BinaryInput::seek(): Position past end" ); } @@ -1581,7 +1581,7 @@ sal_Int16 BinaryInput::readInt16( void ) nRet += 256 * sal_Int16( sal_uInt8( m_pData[m_nCurPos++] ) ); } else - OSL_ENSURE( false, "BinaryInput::readInt16(): Read past end" ); + OSL_FAIL( "BinaryInput::readInt16(): Read past end" ); return nRet; } @@ -1599,7 +1599,7 @@ sal_Int32 BinaryInput::readInt32( void ) } } else - OSL_ENSURE( false, "BinaryInput::readInt32(): Read past end" ); + OSL_FAIL( "BinaryInput::readInt32(): Read past end" ); return nRet; } @@ -1613,7 +1613,7 @@ sal_Unicode BinaryInput::readUnicodeChar( void ) nRet += 256 * sal_uInt8( m_pData[m_nCurPos++] ); } else - OSL_ENSURE( false, "BinaryInput::readUnicodeChar(): Read past end" ); + OSL_FAIL( "BinaryInput::readUnicodeChar(): Read past end" ); sal_Unicode cRet = nRet; return cRet; |