diff options
author | Caolán McNamara <caolanm@redhat.com> | 2014-11-17 12:09:54 +0000 |
---|---|---|
committer | Caolán McNamara <caolanm@redhat.com> | 2014-11-17 14:53:24 +0000 |
commit | 9d3c54c981de898e79885d73103878555b13133b (patch) | |
tree | ec5361035f1753bd90543901adfeae64c91066bd | |
parent | 43d6da691fd23dd788f192f3e5f80676a7acc220 (diff) |
OSL_ENSURE->assert where guaranteed deref follows
Change-Id: I241e13cbf440c1a7e208c2646ded7bf2628ca25b
-rw-r--r-- | sw/source/filter/xml/xmltbli.cxx | 7 |
1 files changed, 3 insertions, 4 deletions
diff --git a/sw/source/filter/xml/xmltbli.cxx b/sw/source/filter/xml/xmltbli.cxx index 9971add2fbcc..a9a9a50aa73b 100644 --- a/sw/source/filter/xml/xmltbli.cxx +++ b/sw/source/filter/xml/xmltbli.cxx @@ -688,10 +688,10 @@ void SwXMLTableCellContext_Impl::EndElement() // Until we have an API for copying we have to use the core. Reference<XUnoTunnel> xSrcCrsrTunnel( xSrcTxtCursor, UNO_QUERY); - OSL_ENSURE( xSrcCrsrTunnel.is(), "missing XUnoTunnel for Cursor" ); + assert(xSrcCrsrTunnel.is() && "missing XUnoTunnel for Cursor"); OTextCursorHelper *pSrcTxtCrsr = reinterpret_cast< OTextCursorHelper * >( sal::static_int_cast< sal_IntPtr >( xSrcCrsrTunnel->getSomething( OTextCursorHelper::getUnoTunnelId() ))); - OSL_ENSURE( pSrcTxtCrsr, "SwXTextCursor missing" ); + assert(pSrcTxtCrsr && "SwXTextCursor missing"); SwDoc *pDoc = pSrcTxtCrsr->GetDoc(); const SwPaM *pSrcPaM = pSrcTxtCrsr->GetPaM(); @@ -701,8 +701,7 @@ void SwXMLTableCellContext_Impl::EndElement() Reference<XUnoTunnel> xDstCrsrTunnel( GetImport().GetTextImport()->GetCursor(), UNO_QUERY); - OSL_ENSURE( xDstCrsrTunnel.is(), - "missing XUnoTunnel for Cursor" ); + assert(xDstCrsrTunnel.is() && "missing XUnoTunnel for Cursor"); OTextCursorHelper *pDstTxtCrsr = reinterpret_cast< OTextCursorHelper * >( sal::static_int_cast< sal_IntPtr >( xDstCrsrTunnel->getSomething( OTextCursorHelper::getUnoTunnelId() )) ); assert(pDstTxtCrsr && "SwXTextCursor missing"); |