From efaadd43016dbc4a229734d19b3801df161b2857 Mon Sep 17 00:00:00 2001 From: kervala Date: Thu, 20 Oct 2016 15:30:12 +0200 Subject: [PATCH 1/3] Changed: Real version of Ryzom Installer as user-agent --HG-- branch : develop --- code/ryzom/tools/client/ryzom_installer/src/downloader.cpp | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/code/ryzom/tools/client/ryzom_installer/src/downloader.cpp b/code/ryzom/tools/client/ryzom_installer/src/downloader.cpp index 298cc5185..d56fa84ac 100644 --- a/code/ryzom/tools/client/ryzom_installer/src/downloader.cpp +++ b/code/ryzom/tools/client/ryzom_installer/src/downloader.cpp @@ -47,7 +47,7 @@ bool CDownloader::getHtmlPageContent(const QString &url) if (url.isEmpty()) return false; QNetworkRequest request(url); - request.setHeader(QNetworkRequest::UserAgentHeader, "Ryzom Installer/1.0"); + request.setHeader(QNetworkRequest::UserAgentHeader, QString("Ryzom Installer/%1").arg(QApplication::applicationVersion())); QNetworkReply *reply = m_manager->get(request); From e50c1fcf9847215e5c32ded02ed0351fd69a6c42 Mon Sep 17 00:00:00 2001 From: kervala Date: Thu, 20 Oct 2016 15:30:30 +0200 Subject: [PATCH 2/3] Changed: Write warnings in log --HG-- branch : develop --- code/ryzom/tools/client/ryzom_installer/src/downloader.cpp | 6 +++--- 1 file changed, 3 insertions(+), 3 deletions(-) diff --git a/code/ryzom/tools/client/ryzom_installer/src/downloader.cpp b/code/ryzom/tools/client/ryzom_installer/src/downloader.cpp index d56fa84ac..72a48fe1e 100644 --- a/code/ryzom/tools/client/ryzom_installer/src/downloader.cpp +++ b/code/ryzom/tools/client/ryzom_installer/src/downloader.cpp @@ -76,7 +76,7 @@ bool CDownloader::getFile() { if (m_fullPath.isEmpty() || m_url.isEmpty()) { - qDebug() << "You forget to call prepareFile before"; + nlwarning("You forget to call prepareFile before"); return false; } @@ -233,7 +233,7 @@ bool CDownloader::checkDownloadedFile() void CDownloader::onTimeout() { - qDebug() << "Timeout"; + nlwarning("Timeout"); if (m_listener) m_listener->operationFail(tr("Timeout")); } @@ -368,7 +368,7 @@ void CDownloader::onHeadFinished() { if (checkDownloadedFile()) { - qDebug() << "same date and size"; + nlwarning("Same date and size"); } else { From d574641c796e2a657cc89f0eea3623d4327ff2b0 Mon Sep 17 00:00:00 2001 From: kervala Date: Thu, 20 Oct 2016 15:30:43 +0200 Subject: [PATCH 3/3] Changed: HTTP code 307 is not an error --HG-- branch : develop --- code/ryzom/tools/client/ryzom_installer/src/downloader.cpp | 7 ------- 1 file changed, 7 deletions(-) diff --git a/code/ryzom/tools/client/ryzom_installer/src/downloader.cpp b/code/ryzom/tools/client/ryzom_installer/src/downloader.cpp index 72a48fe1e..e3a3c3d01 100644 --- a/code/ryzom/tools/client/ryzom_installer/src/downloader.cpp +++ b/code/ryzom/tools/client/ryzom_installer/src/downloader.cpp @@ -350,13 +350,6 @@ void CDownloader::onHeadFinished() } } - // error when download is not yet ready - else if (status == 307) - { - if (m_listener) m_listener->operationFail(tr("File is not available, please retry later (status code: %1)").arg(status)); - return; - } - // other status else {