diff options
author | Stephan Bergmann <sbergman@redhat.com> | 2017-02-14 16:10:56 +0100 |
---|---|---|
committer | Stephan Bergmann <sbergman@redhat.com> | 2017-02-15 14:18:47 +0000 |
commit | 5ce42c21654db41544d831ac18c1388dde64d122 (patch) | |
tree | e85bf95ebf62c88b12d2f77107702feb3e295362 /embeddedobj/source/msole/olevisual.cxx | |
parent | 32cb8a544d25bc2a5150cd6818f505f5d5fa3687 (diff) |
Some simplifications, using UNO_QUERY_THROW
Change-Id: Ieee649609a7f01b4d51ed6ed78a8ae809ca61d9e
Reviewed-on: https://gerrit.libreoffice.org/34268
Tested-by: Stephan Bergmann <sbergman@redhat.com>
Reviewed-by: Stephan Bergmann <sbergman@redhat.com>
Diffstat (limited to 'embeddedobj/source/msole/olevisual.cxx')
-rw-r--r-- | embeddedobj/source/msole/olevisual.cxx | 4 |
1 files changed, 2 insertions, 2 deletions
diff --git a/embeddedobj/source/msole/olevisual.cxx b/embeddedobj/source/msole/olevisual.cxx index 0676d4dba68b..329c4fa17457 100644 --- a/embeddedobj/source/msole/olevisual.cxx +++ b/embeddedobj/source/msole/olevisual.cxx @@ -45,9 +45,9 @@ embed::VisualRepresentation OleEmbeddedObject::GetVisualRepresentationInNativeFo // TODO: detect the format in the future for now use workaround uno::Reference< io::XInputStream > xInStream = xCachedVisRepr->getInputStream(); - uno::Reference< io::XSeekable > xSeekable( xCachedVisRepr, uno::UNO_QUERY ); - if ( !xInStream.is() || !xSeekable.is() ) + if ( !xInStream.is() ) throw uno::RuntimeException(); + uno::Reference< io::XSeekable > xSeekable( xCachedVisRepr, uno::UNO_QUERY_THROW ); uno::Sequence< sal_Int8 > aSeq( 2 ); xInStream->readBytes( aSeq, 2 ); |