diff options
author | Caolán McNamara <caolanm@redhat.com> | 2017-01-21 15:29:17 +0000 |
---|---|---|
committer | Caolán McNamara <caolanm@redhat.com> | 2017-01-21 17:05:32 +0000 |
commit | c15695a998157e07cc3f248d72763048af28b623 (patch) | |
tree | 8c89da3e7add64e7241b71e0737af3362ac47f5e | |
parent | 2fc13fef1478925f5ea447b3b293c2e36c0c6696 (diff) |
coverity#1399021 Unchecked dynamic_cast
Change-Id: I2b43a918f8f01bbe075c2edd8ca963e13588903c
-rw-r--r-- | svx/source/unodraw/UnoGraphicExporter.cxx | 4 |
1 files changed, 2 insertions, 2 deletions
diff --git a/svx/source/unodraw/UnoGraphicExporter.cxx b/svx/source/unodraw/UnoGraphicExporter.cxx index 2a852fce9c3b..0be647033ae8 100644 --- a/svx/source/unodraw/UnoGraphicExporter.cxx +++ b/svx/source/unodraw/UnoGraphicExporter.cxx @@ -721,9 +721,9 @@ bool GraphicExporter::GetGraphic( ExportSettings& rSettings, Graphic& aGraphic, // create a view std::unique_ptr< SdrView > pView; - if( dynamic_cast<FmFormModel*>( mpDoc ) != nullptr ) + if (FmFormModel *pFormModel = dynamic_cast<FmFormModel*>(mpDoc)) { - pView.reset(new FmFormView( dynamic_cast<FmFormModel*>( mpDoc ), aVDev ) ); + pView.reset(new FmFormView(pFormModel, aVDev)); } else { |