mirror of
https://github.com/SabreTools/BinaryObjectScanner.git
synced 2026-08-04 23:19:18 +00:00
Fix crash in SolidShield scanning (fixes #76)
This commit is contained in:
@@ -343,7 +343,16 @@ namespace BurnOutSharp.ExecutableType.Microsoft
|
||||
int startingIndex = (int)Math.Max(section.PointerToRawData + offset, 0);
|
||||
int readLength = (int)Math.Min(section.VirtualSize - offset, content.Length);
|
||||
|
||||
return content.ReadBytes(ref startingIndex, readLength);
|
||||
try
|
||||
{
|
||||
return content.ReadBytes(ref startingIndex, readLength);
|
||||
}
|
||||
catch
|
||||
{
|
||||
// Just absorb errors for now
|
||||
// TODO: Investigate why and when this would be hit
|
||||
return null;
|
||||
}
|
||||
}
|
||||
|
||||
#endregion
|
||||
|
||||
Reference in New Issue
Block a user