[Refactor] General reformat and clean-up.

This commit is contained in:
2025-11-24 20:12:10 +00:00
parent 8331fba1e4
commit a58f2e60e5
415 changed files with 4920 additions and 4829 deletions

View File

@@ -28,12 +28,12 @@ public partial class HaStream : Stream
// Read full compressed data into memory
compressedStream.Position = 0;
byte[] inBuf = new byte[compressedStream.Length];
var inBuf = new byte[compressedStream.Length];
compressedStream.ReadExactly(inBuf, 0, inBuf.Length);
// Allocate output buffer
_decoded = new byte[decompressedLength];
nint outLen = (nint)decompressedLength;
var outLen = (nint)decompressedLength;
// Call native decompressor
int err;
@@ -96,7 +96,7 @@ public partial class HaStream : Stream
if(remaining <= 0) return 0;
int toRead = (int)Math.Min(count, remaining);
var toRead = (int)Math.Min(count, remaining);
Array.Copy(_decoded, _position, buffer, offset, toRead);
_position += toRead;