mirror of
https://github.com/aaru-dps/Aaru.git
synced 2025-12-16 19:24:25 +00:00
Fix AaruFormat's DDT verification when its size on-image is bigger than 1MiB. Fixes #726
(cherry picked from commit e803ae4519)
This commit is contained in:
@@ -151,13 +151,13 @@ namespace Aaru.DiscImages
|
||||
"Verifying deduplication table type {0} at position {1}",
|
||||
entry.dataType, entry.offset);
|
||||
|
||||
while(readBytes + verifySize < ddtHeader.cmpLength)
|
||||
{
|
||||
verifyBytes = new byte[readBytes];
|
||||
_imageStream.Read(verifyBytes, 0, verifyBytes.Length);
|
||||
crcVerify.Update(verifyBytes);
|
||||
readBytes += (ulong)verifyBytes.LongLength;
|
||||
}
|
||||
while(readBytes + verifySize < ddtHeader.cmpLength)
|
||||
{
|
||||
verifyBytes = new byte[verifySize];
|
||||
_imageStream.Read(verifyBytes, 0, verifyBytes.Length);
|
||||
crcVerify.Update(verifyBytes);
|
||||
readBytes += (ulong)verifyBytes.LongLength;
|
||||
}
|
||||
|
||||
verifyBytes = new byte[ddtHeader.cmpLength - readBytes];
|
||||
_imageStream.Read(verifyBytes, 0, verifyBytes.Length);
|
||||
|
||||
Reference in New Issue
Block a user