mirror of
https://github.com/PrismLauncher/PrismLauncher
synced 2026-04-23 09:05:03 +00:00
Fix(NetJob): do not call emitAborted() when not running
Signed-off-by: 0x189D7997 <199489335+0x189D7997@users.noreply.github.com>
This commit is contained in:
parent
15b39af92e
commit
ffded2ccac
|
|
@ -100,13 +100,18 @@ auto NetJob::canAbort() const -> bool
|
|||
|
||||
auto NetJob::abort() -> bool
|
||||
{
|
||||
bool fullyAborted = true;
|
||||
|
||||
// fail all downloads on the queue
|
||||
for (auto task : m_queue)
|
||||
m_failed.insert(task.get(), task);
|
||||
m_queue.clear();
|
||||
|
||||
if (m_doing.isEmpty()) {
|
||||
// no downloads to abort, NetJob is not running
|
||||
return true;
|
||||
}
|
||||
|
||||
bool fullyAborted = true;
|
||||
|
||||
// abort active downloads
|
||||
auto toKill = m_doing.values();
|
||||
for (auto part : toKill) {
|
||||
|
|
|
|||
Loading…
Reference in a new issue