chart2/source/model/filter/XMLFilter.cxx | 23 +++++++++-------------- 1 file changed, 9 insertions(+), 14 deletions(-)
New commits: commit f488136a72f626c6752538fbc80efe13053cead5 Author: Xisco Fauli <xiscofa...@libreoffice.org> AuthorDate: Thu Oct 17 17:15:14 2024 +0200 Commit: Xisco Fauli <xiscofa...@libreoffice.org> CommitDate: Thu Oct 17 22:23:26 2024 +0200 tdf#163486: PVS: Expression is always false V547: Expression 'aMDHelper.ISSET_Storage' is always false. Change-Id: Ibdeb820b606301f729bf09a3641ab44d726e356c Reviewed-on: https://gerrit.libreoffice.org/c/core/+/175095 Reviewed-by: Xisco Fauli <xiscofa...@libreoffice.org> Tested-by: Jenkins diff --git a/chart2/source/model/filter/XMLFilter.cxx b/chart2/source/model/filter/XMLFilter.cxx index 0422216fe9fd..f68081330347 100644 --- a/chart2/source/model/filter/XMLFilter.cxx +++ b/chart2/source/model/filter/XMLFilter.cxx @@ -91,21 +91,16 @@ uno::Reference< embed::XStorage > lcl_getWriteStorage( } } - if( aMDHelper.ISSET_Storage ) - xStorage.set( aMDHelper.Storage ); - else - { - Sequence< uno::Any > aStorageArgs{ - aMDHelper.ISSET_OutputStream ? uno::Any(aMDHelper.OutputStream) - : uno::Any(aMDHelper.URL), - uno::Any(embed::ElementModes::READWRITE | embed::ElementModes::TRUNCATE), - uno::Any(comphelper::containerToSequence( aPropertiesForStorage )) - }; + Sequence< uno::Any > aStorageArgs{ + aMDHelper.ISSET_OutputStream ? uno::Any(aMDHelper.OutputStream) + : uno::Any(aMDHelper.URL), + uno::Any(embed::ElementModes::READWRITE | embed::ElementModes::TRUNCATE), + uno::Any(comphelper::containerToSequence( aPropertiesForStorage )) + }; - xStorage.set( - xStorageFact->createInstanceWithArguments( aStorageArgs ), - uno::UNO_QUERY_THROW ); - } + xStorage.set( + xStorageFact->createInstanceWithArguments( aStorageArgs ), + uno::UNO_QUERY_THROW ); } // set correct media type at storage