Both, both is good

This commit is contained in:
Matt Nadareski
2022-12-03 23:48:48 -08:00
parent a6862925ca
commit 26831b4732

View File

@@ -715,7 +715,7 @@ namespace BurnOutSharp.Builder
attributeCertificateTable.Add(entry);
// Align to the 8-byte boundary
while (offset < endOffset - 1 && (offset % 8) != 0)
while ((offset % 8) != 0 && offset < endOffset - 1 && offset != data.Length - 1)
_ = data.ReadByte(ref offset);
}
@@ -1866,7 +1866,7 @@ namespace BurnOutSharp.Builder
attributeCertificateTable.Add(entry);
// Align to the 8-byte boundary
while (data.Position < endOffset - 1 && (data.Position % 8) != 0)
while ((data.Position % 8) != 0 && data.Position < endOffset - 1 && data.Position != data.Length - 1)
_ = data.ReadByteValue();
}