mirror of
https://github.com/aaru-dps/Aaru.git
synced 2025-12-16 19:24:25 +00:00
Don't try to read past partition end.
This commit is contained in:
@@ -121,6 +121,9 @@ namespace DiscImageChef.Filesystems
|
||||
if(Marshal.SizeOf(reiserSb) % imagePlugin.GetSectorSize() != 0)
|
||||
sbSize++;
|
||||
|
||||
if(partition.Start + sbAddr + sbSize >= partition.End)
|
||||
return false;
|
||||
|
||||
byte[] sector = imagePlugin.ReadSectors(partition.Start + sbAddr, sbSize);
|
||||
if(sector.Length < Marshal.SizeOf(reiserSb))
|
||||
return false;
|
||||
|
||||
Reference in New Issue
Block a user