mirror of
https://github.com/cmclark00/retro-imager.git
synced 2025-05-18 07:55:21 +01:00
Fix verifying on images that are not dividable by block size
This commit is contained in:
parent
75feb3e73d
commit
a367ed0683
1 changed files with 1 additions and 1 deletions
|
@ -610,7 +610,7 @@ bool DownloadThread::_verify()
|
|||
|
||||
while (_verifyEnabled && _lastVerifyNow < _verifyTotal && !_cancelled)
|
||||
{
|
||||
qint64 lenRead = _file.read(verifyBuf, IMAGEWRITER_VERIFY_BLOCKSIZE);
|
||||
qint64 lenRead = _file.read(verifyBuf, qMin((qint64) IMAGEWRITER_VERIFY_BLOCKSIZE, (qint64) (_verifyTotal-_lastVerifyNow) ));
|
||||
if (lenRead == -1)
|
||||
{
|
||||
DownloadThread::_onDownloadError(tr("Error reading from storage.\n"
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue