forked from qt-creator/qt-creator
QMake: Clean up Qmakestep
Change-Id: I3a2baa4e15a48f99652cec6151803f20341e339a Reviewed-by: Tim Jenssen <tim.jenssen@qt.io>
This commit is contained in:
@@ -336,8 +336,7 @@ void QMakeStep::startOneCommand(const QString &command, const QString &args)
|
||||
pp->resolveAll();
|
||||
|
||||
QTC_ASSERT(!m_commandFuture || m_commandFuture->future().isFinished(), return);
|
||||
delete m_commandFuture;
|
||||
m_commandFuture = new QFutureInterface<bool>;
|
||||
m_commandFuture.reset(new QFutureInterface<bool>);
|
||||
|
||||
m_commandWatcher.setFuture(m_commandFuture->future());
|
||||
AbstractProcessStep::run(*m_commandFuture);
|
||||
@@ -355,8 +354,7 @@ void QMakeStep::runNextCommand()
|
||||
wasSuccess = false; // should not happen
|
||||
}
|
||||
|
||||
delete m_commandFuture;
|
||||
m_commandFuture = nullptr;
|
||||
m_commandFuture.reset();
|
||||
|
||||
if (!wasSuccess)
|
||||
m_nextState = State::POST_PROCESS;
|
||||
|
@@ -177,7 +177,7 @@ private:
|
||||
|
||||
QFutureInterface<bool> m_inputFuture;
|
||||
QFutureWatcher<bool> m_inputWatcher;
|
||||
QFutureInterface<bool> *m_commandFuture = nullptr;
|
||||
std::unique_ptr<QFutureInterface<bool>> m_commandFuture;
|
||||
QFutureWatcher<bool> m_commandWatcher;
|
||||
|
||||
// last values
|
||||
|
Reference in New Issue
Block a user