refactor: Log server response on version check error
Qt `errorString()` only contains the error code and error text, but not the response body. And, in HTTP/2 the error string is gone but the error is still printed like it's there: https://bugreports.qt.io/browse/QTBUG-140126
This commit is contained in:
@ -39,6 +39,7 @@ void VersionChecker::replyFinished(QNetworkReply *reply)
|
||||
const auto httpStatus = reply->attribute(QNetworkRequest::HttpStatusCodeAttribute).toInt();
|
||||
if (reply->error() != QNetworkReply::NoError) {
|
||||
qWarning("version check server error: %s", qPrintable(reply->errorString()));
|
||||
qWarning("version check server response: %s", qPrintable(QString(reply->readAll())));
|
||||
qWarning("error checking for updates, http status: %d", httpStatus);
|
||||
return;
|
||||
}
|
||||
|
||||
Reference in New Issue
Block a user