diff options
Diffstat (limited to 'ucb/source/ucp/cmis')
-rw-r--r-- | ucb/source/ucp/cmis/cmis_datasupplier.cxx | 48 |
1 files changed, 24 insertions, 24 deletions
diff --git a/ucb/source/ucp/cmis/cmis_datasupplier.cxx b/ucb/source/ucp/cmis/cmis_datasupplier.cxx index 2a91770cd8f6..21ac2602de41 100644 --- a/ucb/source/ucp/cmis/cmis_datasupplier.cxx +++ b/ucb/source/ucp/cmis/cmis_datasupplier.cxx @@ -107,34 +107,34 @@ namespace cmis } } - if ( getResult( nIndex ) ) + if ( !getResult( nIndex ) ) + return {}; + + uno::Reference< ucb::XContent > xContent( queryContent( nIndex ) ); + if ( !xContent ) + return {}; + try { - uno::Reference< ucb::XContent > xContent( queryContent( nIndex ) ); - if ( xContent.is() ) + uno::Reference< ucb::XCommandProcessor > xCmdProc( xContent, uno::UNO_QUERY ); + if ( !xCmdProc ) + return {}; + sal_Int32 nCmdId( xCmdProc->createCommandIdentifier() ); + ucb::Command aCmd; + aCmd.Name = "getPropertyValues"; + aCmd.Handle = -1; + aCmd.Argument <<= getResultSet()->getProperties(); + uno::Any aResult( xCmdProc->execute( + aCmd, nCmdId, getResultSet()->getEnvironment() ) ); + uno::Reference< sdbc::XRow > xRow; + if ( aResult >>= xRow ) { - try - { - uno::Reference< ucb::XCommandProcessor > xCmdProc( - xContent, uno::UNO_QUERY_THROW ); - sal_Int32 nCmdId( xCmdProc->createCommandIdentifier() ); - ucb::Command aCmd; - aCmd.Name = "getPropertyValues"; - aCmd.Handle = -1; - aCmd.Argument <<= getResultSet()->getProperties(); - uno::Any aResult( xCmdProc->execute( - aCmd, nCmdId, getResultSet()->getEnvironment() ) ); - uno::Reference< sdbc::XRow > xRow; - if ( aResult >>= xRow ) - { - maResults[ nIndex ].xRow = xRow; - return xRow; - } - } - catch ( uno::Exception const & ) - { - } + maResults[ nIndex ].xRow = xRow; + return xRow; } } + catch ( uno::Exception const & ) + { + } return uno::Reference< sdbc::XRow >(); } |