diff options
author | Noel Grandin <noel@peralex.com> | 2016-04-12 16:39:03 +0200 |
---|---|---|
committer | Noel Grandin <noelgrandin@gmail.com> | 2016-04-18 07:37:31 +0000 |
commit | 789055bc2acb4c71483fd60ea258d158bd5aec10 (patch) | |
tree | 7849de841a71f667a30b2a971ad0c3d406110396 /sd/source/ui/app/sdmod1.cxx | |
parent | 150ac9cf05ed9da6a2af5bc3f820280fd853e519 (diff) |
clang-tidy performance-unnecessary-copy-initialization
probably not much performance benefit, but it sure is good at
identifying leftover intermediate variables from previous
refactorings.
Change-Id: I3ce16fe496ac2733c1cb0a35f74c0fc9193cc657
Reviewed-on: https://gerrit.libreoffice.org/24026
Reviewed-by: Noel Grandin <noelgrandin@gmail.com>
Tested-by: Noel Grandin <noelgrandin@gmail.com>
Diffstat (limited to 'sd/source/ui/app/sdmod1.cxx')
-rw-r--r-- | sd/source/ui/app/sdmod1.cxx | 8 |
1 files changed, 3 insertions, 5 deletions
diff --git a/sd/source/ui/app/sdmod1.cxx b/sd/source/ui/app/sdmod1.cxx index c3606cae3f83..4d45f0a72165 100644 --- a/sd/source/ui/app/sdmod1.cxx +++ b/sd/source/ui/app/sdmod1.cxx @@ -567,14 +567,12 @@ SfxFrame* SdModule::ExecuteNewDocument( SfxRequest& rReq ) if( pPilotDlg->GetStartType() == ST_OPEN ) { - OUString aFileToOpen = aDocPath; - - DBG_ASSERT( !aFileToOpen.isEmpty(), "The autopilot should have asked for a file itself already!" ); - if (!aFileToOpen.isEmpty()) + DBG_ASSERT( !aDocPath.isEmpty(), "The autopilot should have asked for a file itself already!" ); + if (!aDocPath.isEmpty()) { css::uno::Sequence< css::beans::NamedValue > aPasswrd( pPilotDlg->GetPassword() ); - SfxStringItem aFile( SID_FILE_NAME, aFileToOpen ); + SfxStringItem aFile( SID_FILE_NAME, aDocPath ); SfxStringItem aReferer( SID_REFERER, OUString()); SfxUnoAnyItem aPassword( SID_ENCRYPTIONDATA, css::uno::makeAny(aPasswrd) ); |