mirror of
https://github.com/martinrotter/rssguard.git
synced 2024-12-26 16:13:32 +01:00
fix crash when downloading files repeatedly
This commit is contained in:
parent
28edff70a7
commit
0c2943e85e
@ -320,7 +320,7 @@ void DownloadItem::downloadProgress(qint64 bytes_received, qint64 bytes_total) {
|
||||
}
|
||||
|
||||
qint64 DownloadItem::bytesTotal() const {
|
||||
return m_reply->header(QNetworkRequest::ContentLengthHeader).toULongLong();
|
||||
return m_reply == nullptr ? 0 : m_reply->header(QNetworkRequest::ContentLengthHeader).toULongLong();
|
||||
}
|
||||
|
||||
qint64 DownloadItem::bytesReceived() const {
|
||||
|
Loading…
Reference in New Issue
Block a user