diff options
author | Stephan Bergmann <sbergman@redhat.com> | 2014-10-24 10:22:49 +0200 |
---|---|---|
committer | Stephan Bergmann <sbergman@redhat.com> | 2014-10-24 10:22:49 +0200 |
commit | 1ff8fbba36e00170c65572fbe21e8e51925ac8ae (patch) | |
tree | a421a66a8653d8113d526351d99f12f3bb7e4fd1 | |
parent | 6805d77c70c98d6fadccb3d4d8c0823924aca18b (diff) |
Some OSL_ENSURE -> assert
Change-Id: Idd165c4a3083e1d4d8d1d16c663c31653c108702
-rw-r--r-- | sw/source/filter/xml/xmlimp.cxx | 8 |
1 files changed, 6 insertions, 2 deletions
diff --git a/sw/source/filter/xml/xmlimp.cxx b/sw/source/filter/xml/xmlimp.cxx index b1384c08ae62..ab2e6431968b 100644 --- a/sw/source/filter/xml/xmlimp.cxx +++ b/sw/source/filter/xml/xmlimp.cxx @@ -17,6 +17,10 @@ * the License at http://www.apache.org/licenses/LICENSE-2.0 . */ +#include <sal/config.h> + +#include <cassert> + #include <com/sun/star/container/XIndexAccess.hpp> #include <com/sun/star/document/PrinterIndependentLayout.hpp> #include <com/sun/star/drawing/XDrawPage.hpp> @@ -1598,8 +1602,8 @@ SwDoc* SwImport::GetDocFromXMLImport( SvXMLImport& rImport ) uno::Reference<lang::XUnoTunnel> xModelTunnel( rImport.GetModel(), uno::UNO_QUERY ); SwXTextDocument *pTxtDoc = reinterpret_cast< SwXTextDocument *>( sal::static_int_cast< sal_IntPtr >( xModelTunnel->getSomething(SwXTextDocument::getUnoTunnelId() ))); - OSL_ENSURE( pTxtDoc, "Where is my model?" ); - OSL_ENSURE( pTxtDoc->GetDocShell(), "Where is my shell?" ); + assert( pTxtDoc ); + assert( pTxtDoc->GetDocShell() ); SwDoc* pDoc = pTxtDoc->GetDocShell()->GetDoc(); OSL_ENSURE( pDoc, "Where is my document?" ); return pDoc; |