[Libreoffice-commits] core.git: desktop/source

Libreoffice Gerrit user logerrit at kemper.freedesktop.org
Mon Oct 29 11:26:55 UTC 2018


 desktop/source/deployment/dp_log.cxx             |    1 -
 desktop/source/deployment/manager/dp_manager.cxx |    3 +--
 desktop/source/pkgchk/unopkg/unopkg_app.cxx      |    5 ++---
 desktop/source/pkgchk/unopkg/unopkg_cmdenv.cxx   |   20 +++++++-------------
 desktop/source/pkgchk/unopkg/unopkg_shared.h     |    1 -
 5 files changed, 10 insertions(+), 20 deletions(-)

New commits:
commit c2a19eb8b94dd01d306fcae6a2fd974ef3298c3d
Author:     Samuel Mehrbrodt <Samuel.Mehrbrodt at cib.de>
AuthorDate: Mon Oct 29 09:42:36 2018 +0100
Commit:     Samuel Mehrbrodt <Samuel.Mehrbrodt at cib.de>
CommitDate: Mon Oct 29 12:26:32 2018 +0100

    Remove unused parameter
    
    Change-Id: I5b53e8d270f5b87cb3068943d35c17e1f041d1a5
    Reviewed-on: https://gerrit.libreoffice.org/62497
    Tested-by: Jenkins
    Reviewed-by: Samuel Mehrbrodt <Samuel.Mehrbrodt at cib.de>

diff --git a/desktop/source/deployment/dp_log.cxx b/desktop/source/deployment/dp_log.cxx
index dd93e3bc1bdd..3cfdb338d9b7 100644
--- a/desktop/source/deployment/dp_log.cxx
+++ b/desktop/source/deployment/dp_log.cxx
@@ -49,7 +49,6 @@ typedef ::cppu::WeakComponentImplHelper<ucb::XProgressHandler> t_log_helper;
 
 class ProgressLogImpl : public ::dp_misc::MutexHolder, public t_log_helper
 {
-    Reference<io::XOutputStream> m_xLogFile;
     std::unique_ptr<comphelper::EventLogger> m_logger;
 
 protected:
diff --git a/desktop/source/deployment/manager/dp_manager.cxx b/desktop/source/deployment/manager/dp_manager.cxx
index d2c33e298199..25ca6cdcc2d1 100644
--- a/desktop/source/deployment/manager/dp_manager.cxx
+++ b/desktop/source/deployment/manager/dp_manager.cxx
@@ -430,12 +430,11 @@ Reference<deployment::XPackageManager> PackageManagerImpl::create(
             xFileHandler->setLevel(LogLevel::WARNING);
             xLogger->addLogHandler(xFileHandler);
 
-            const Any any_logFile(logFile);
             that->m_xLogFile.set(
                 that->m_xComponentContext->getServiceManager()
                 ->createInstanceWithArgumentsAndContext(
                     dp_log::serviceDecl.getSupportedServiceNames()[0],
-                    Sequence<Any>( &any_logFile, 1 ),
+                    Sequence<Any>(),
                     that->m_xComponentContext ),
                 UNO_QUERY_THROW );
             xCmdEnv.set( new CmdEnvWrapperImpl( xCmdEnv, that->m_xLogFile ) );
diff --git a/desktop/source/pkgchk/unopkg/unopkg_app.cxx b/desktop/source/pkgchk/unopkg/unopkg_app.cxx
index edbc84eff605..725067c20925 100644
--- a/desktop/source/pkgchk/unopkg/unopkg_app.cxx
+++ b/desktop/source/pkgchk/unopkg/unopkg_app.cxx
@@ -386,9 +386,8 @@ extern "C" int unopkg_main()
         Reference<deployment::XExtensionManager> xExtensionManager(
             deployment::ExtensionManager::get( xComponentContext ) );
 
-        Reference< css::ucb::XCommandEnvironment > xCmdEnv(
-            createCmdEnv( xComponentContext, logFile,
-                          option_force, option_verbose, option_suppressLicense) );
+        Reference<css::ucb::XCommandEnvironment> xCmdEnv(
+            createCmdEnv(xComponentContext, option_force, option_verbose, option_suppressLicense));
 
         //synchronize bundled/shared extensions
         //Do not synchronize when command is "reinstall". This could add types and services to UNO and
diff --git a/desktop/source/pkgchk/unopkg/unopkg_cmdenv.cxx b/desktop/source/pkgchk/unopkg/unopkg_cmdenv.cxx
index 2ef5295ec68a..2cb0ebf0dec3 100644
--- a/desktop/source/pkgchk/unopkg/unopkg_cmdenv.cxx
+++ b/desktop/source/pkgchk/unopkg/unopkg_cmdenv.cxx
@@ -73,7 +73,6 @@ public:
     virtual ~CommandEnvironmentImpl() override;
     CommandEnvironmentImpl(
         Reference<XComponentContext> const & xComponentContext,
-        OUString const & log_file,
         bool option_force_overwrite,
         bool option_verbose,
         bool option_suppress_license);
@@ -96,7 +95,6 @@ public:
 
 CommandEnvironmentImpl::CommandEnvironmentImpl(
     Reference<XComponentContext> const & xComponentContext,
-    OUString const & log_file,
     bool option_force_overwrite,
     bool option_verbose,
     bool option_suppressLicense)
@@ -106,15 +104,12 @@ CommandEnvironmentImpl::CommandEnvironmentImpl(
       m_option_suppress_license( option_suppressLicense ),
       m_xComponentContext(xComponentContext)
 {
-    if (!log_file.isEmpty()) {
-        const Any logfile(log_file);
-        m_xLogFile.set(
-            xComponentContext->getServiceManager()
-            ->createInstanceWithArgumentsAndContext(
-                "com.sun.star.comp.deployment.ProgressLog",
-                Sequence<Any>( &logfile, 1 ), xComponentContext ),
-            UNO_QUERY_THROW );
-    }
+    m_xLogFile.set(
+        xComponentContext->getServiceManager()
+        ->createInstanceWithArgumentsAndContext(
+            "com.sun.star.comp.deployment.ProgressLog",
+            Sequence<Any>(), xComponentContext ),
+        UNO_QUERY_THROW );
 }
 
 
@@ -381,13 +376,12 @@ namespace unopkg {
 
 Reference< XCommandEnvironment > createCmdEnv(
     Reference< XComponentContext > const & xContext,
-    OUString const & logFile,
     bool option_force_overwrite,
     bool option_verbose,
     bool option_suppress_license)
 {
     return new CommandEnvironmentImpl(
-        xContext, logFile, option_force_overwrite, option_verbose, option_suppress_license);
+        xContext, option_force_overwrite, option_verbose, option_suppress_license);
 }
 } // unopkg
 
diff --git a/desktop/source/pkgchk/unopkg/unopkg_shared.h b/desktop/source/pkgchk/unopkg/unopkg_shared.h
index 0028880b16aa..6d23b4c8f39e 100644
--- a/desktop/source/pkgchk/unopkg/unopkg_shared.h
+++ b/desktop/source/pkgchk/unopkg/unopkg_shared.h
@@ -94,7 +94,6 @@ OUString makeAbsoluteFileUrl(
 
 css::uno::Reference<css::ucb::XCommandEnvironment> createCmdEnv(
     css::uno::Reference<css::uno::XComponentContext> const & xContext,
-    OUString const & logFile,
     bool option_force_overwrite,
     bool option_verbose,
     bool option_suppressLicense);


More information about the Libreoffice-commits mailing list