Disable changes from #1954

This commit is contained in:
ds5678 2025-10-09 18:06:10 -07:00
parent b328be9ec6
commit 5cf6fbad22
2 changed files with 5 additions and 1 deletions

View File

@ -33,7 +33,7 @@ internal sealed class BundleFileBlockReader : IDisposable
// Avoid storing entire non-compresed entries in memory by mapping a stream to the block location.
if (m_blocksInfo.StorageBlocks.Length == 1 && m_blocksInfo.StorageBlocks[0].CompressionType == CompressionType.None)
{
return m_stream.CreatePartial(m_dataOffset + entry.Offset, entry.Size);
//return m_stream.CreatePartial(m_dataOffset + entry.Offset, entry.Size);
}
// find block offsets

View File

@ -38,6 +38,10 @@ internal sealed class RandomAccessStream : Stream
public RandomAccessStream(FileStream parent, long offset, long length)
{
if (parent.Length < offset + length)
{
throw new ArgumentException("The parent stream is not long enough for the given offset and length.");
}
Parent = parent;
Handle = parent.SafeFileHandle;
BaseOffset = offset;