From 84de21b702e1edc2f717f728872429c407343980 Mon Sep 17 00:00:00 2001 From: Jarek Kobus Date: Wed, 13 Jul 2022 23:42:11 +0200 Subject: [PATCH] VcsCommand: Don't store the FutureProgress Amends 9891a879aa41d3ba6b746d7a6209ac85cd77262c Change-Id: I164eda5935847343bf76bfbcf650ba372ccb6681 Reviewed-by: Orgad Shaneh --- src/plugins/vcsbase/vcscommand.cpp | 5 ++--- src/plugins/vcsbase/vcscommand.h | 4 ---- 2 files changed, 2 insertions(+), 7 deletions(-) diff --git a/src/plugins/vcsbase/vcscommand.cpp b/src/plugins/vcsbase/vcscommand.cpp index 02f7cb1a25b..8ef0cf52b03 100644 --- a/src/plugins/vcsbase/vcscommand.cpp +++ b/src/plugins/vcsbase/vcscommand.cpp @@ -28,7 +28,6 @@ #include "vcsoutputwindow.h" #include "vcsplugin.h" -#include #include #include #include @@ -90,7 +89,7 @@ void VcsCommand::addTask(const QFuture &future) const QString name = displayName(); const auto id = Id::fromString(name + QLatin1String(".action")); if (hasProgressParser()) { - m_progress = ProgressManager::addTask(future, name, id); + ProgressManager::addTask(future, name, id); } else { // add a timed tasked based on timeout // we cannot access the future interface directly, so we need to create a new one @@ -103,7 +102,7 @@ void VcsCommand::addTask(const QFuture &future) watcher->deleteLater(); }); watcher->setFuture(future); - m_progress = ProgressManager::addTimedTask(*fi, name, id, qMax(2, timeoutS() / 5)/*itsmagic*/); + ProgressManager::addTimedTask(*fi, name, id, qMax(2, timeoutS() / 5)/*itsmagic*/); } Internal::VcsPlugin::addFuture(future); diff --git a/src/plugins/vcsbase/vcscommand.h b/src/plugins/vcsbase/vcscommand.h index fd131089a46..634981ff4af 100644 --- a/src/plugins/vcsbase/vcscommand.h +++ b/src/plugins/vcsbase/vcscommand.h @@ -25,11 +25,8 @@ #pragma once -#include #include -#include - namespace VcsBase { class VcsCommand : public Utils::ShellCommand @@ -43,7 +40,6 @@ private: void addTask(const QFuture &future); void postRunCommand(const Utils::FilePath &workDirectory); - QPointer m_progress; bool m_preventRepositoryChanged; friend class VcsBaseClientImpl;