!56 修复下载提前退出

* 	修改:     src/main.cpp
* 	修改:     debian/changelog
* fix: waitforfinished
This commit is contained in:
2022-07-08 09:37:36 +00:00
committed by shenmo
parent 198384c552
commit 0dc594b3f1
3 changed files with 12 additions and 6 deletions

View File

@@ -176,11 +176,9 @@ void DownloadController::startDownload(const QString &url)
auto pidNumber = cmd->processId();
this->pidNumber = pidNumber;
int statusSum = 0;
while (statusSum > -20)
while (cmd->waitForFinished(-1))
{
auto status = cmd->waitForFinished() - 1;
statusSum += status;
continue;
}
emit downloadFinished();
});