Log error properly

This commit is contained in:
Chocobo1 2019-10-27 14:32:32 +08:00
parent a3fd340187
commit 89c58921de
No known key found for this signature in database
GPG key ID: 210D9C873253A68C

View file

@ -30,7 +30,6 @@
#include "session.h"
#include <algorithm>
#include <cstdlib>
#include <queue>
#include <string>
#include <utility>
@ -2185,8 +2184,6 @@ void Session::generateResumeData(const bool final)
// Called on exit
void Session::saveResumeData()
{
qDebug("Saving resume data...");
// Pause session
m_nativeSession->pause();
@ -2197,7 +2194,8 @@ void Session::saveResumeData()
while (m_numResumeData > 0) {
const std::vector<lt::alert *> alerts = getPendingAlerts(lt::seconds(30));
if (alerts.empty()) {
fprintf(stderr, " aborting with %d outstanding torrents to save resume data for\n", m_numResumeData);
LogMsg(tr("Error: Aborted saving resume data for %1 outstanding torrents.").arg(QString::number(m_numResumeData))
, Log::CRITICAL);
break;
}