From 9fd89a5952a48b473cee03a2681eb5d4cd6d1742 Mon Sep 17 00:00:00 2001 From: Ɓukasz Hryniuk Date: Sun, 4 Jan 2015 22:50:05 +0100 Subject: fdo#39440 reduce scope of local variables Beside scope changes, it fixes lack of initialization in a few places. Change-Id: Ia09fdb9845d8ac17256330a5ec5168401c84f0f2 Reviewed-on: https://gerrit.libreoffice.org/13755 Reviewed-by: Noel Grandin Tested-by: Noel Grandin --- desktop/source/app/app.cxx | 3 +-- desktop/source/deployment/manager/dp_extensionmanager.cxx | 2 +- 2 files changed, 2 insertions(+), 3 deletions(-) (limited to 'desktop') diff --git a/desktop/source/app/app.cxx b/desktop/source/app/app.cxx index e5f0a84240f4..af0cf51f2fcd 100644 --- a/desktop/source/app/app.cxx +++ b/desktop/source/app/app.cxx @@ -2690,7 +2690,6 @@ void Desktop::HandleAppEvent( const ApplicationEvent& rAppEvent ) void Desktop::OpenSplashScreen() { const CommandLineArgs &rCmdLine = GetCommandLineArgs(); - bool bVisible = false; // Show intro only if this is normal start (e.g. no server, no quickstart, no printing ) if ( !rCmdLine.IsInvisible() && !rCmdLine.IsHeadless() && @@ -2726,7 +2725,7 @@ void Desktop::OpenSplashScreen() if ( rCmdLine.HasSplashPipe() ) aSplashService = "com.sun.star.office.PipeSplashScreen"; - bVisible = true; + bool bVisible = true; Sequence< Any > aSeq( 2 ); aSeq[0] <<= bVisible; aSeq[1] <<= aAppName; diff --git a/desktop/source/deployment/manager/dp_extensionmanager.cxx b/desktop/source/deployment/manager/dp_extensionmanager.cxx index 4643794625e3..345a3e0a574b 100644 --- a/desktop/source/deployment/manager/dp_extensionmanager.cxx +++ b/desktop/source/deployment/manager/dp_extensionmanager.cxx @@ -680,7 +680,6 @@ Reference ExtensionManager::addExtension( Reference xExtensionBackup; uno::Any excOccurred2; - bool bUserDisabled = false; bool bCanInstall = doChecksForAddExtension( xPackageManager, properties, @@ -690,6 +689,7 @@ Reference ExtensionManager::addExtension( xOldExtension ); { + bool bUserDisabled = false; // In this garded section (getMutex) we must not use the argument xCmdEnv // because it may bring up dialogs (XInteractionHandler::handle) this //may potententially deadlock. See issue -- cgit