From 5708534b942c1d0ce384f6a8473da6bb569410e7 Mon Sep 17 00:00:00 2001 From: Noel Grandin Date: Thu, 7 Jun 2018 13:03:58 +0200 Subject: look for unnecessary calls to Reference::is() after an UNO_QUERY_THROW Since the previous call would throw if there was nothing to be assigned to the value. Idea from tml. Used the following script to find places: git grep -A3 -n UNO_QUERY_THROW | grep -B3 -F 'is()' Change-Id: I36ba7b00bcd014bdf16c0455ab91056f82194969 Reviewed-on: https://gerrit.libreoffice.org/55417 Tested-by: Jenkins Reviewed-by: Tor Lillqvist Reviewed-by: Mike Kaganski --- xmlscript/source/xmldlg_imexp/imp_share.hxx | 3 +-- 1 file changed, 1 insertion(+), 2 deletions(-) (limited to 'xmlscript/source/xmldlg_imexp') diff --git a/xmlscript/source/xmldlg_imexp/imp_share.hxx b/xmlscript/source/xmldlg_imexp/imp_share.hxx index c93bd905d363..89ec490d46d5 100644 --- a/xmlscript/source/xmldlg_imexp/imp_share.hxx +++ b/xmlscript/source/xmldlg_imexp/imp_share.hxx @@ -163,8 +163,7 @@ public: , _xDialogModelFactory( xDialogModel, css::uno::UNO_QUERY_THROW ) , XMLNS_DIALOGS_UID( 0 ) , XMLNS_SCRIPT_UID( 0 ) - { OSL_ASSERT( _xDialogModel.is() && _xDialogModelFactory.is() && - _xContext.is() ); } + { OSL_ASSERT( _xDialogModel.is() && _xContext.is() ); } DialogImport( const DialogImport& rOther ) : ::cppu::WeakImplHelper< css::xml::input::XRoot >() , _xContext( rOther._xContext ) -- cgit