Skip to content

Commit ee0b4e9

Browse files
Fixed oodle compressor to remove unused part of buffer
1 parent 58e0077 commit ee0b4e9

File tree

1 file changed

+1
-1
lines changed

1 file changed

+1
-1
lines changed

UnrealReZen/Core/Compression/Compressions.cs

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -59,7 +59,7 @@ private static byte[] CompressOodle(byte[] inData)
5959
var compressedBufferSize = (int)_oodle.GetCompressedBufferSizeNeeded(compressor, inData.Length);
6060
var compressedBuffer = new byte[compressedBufferSize];
6161
var compressedSize = (int)_oodle.Compress(compressor, OodleCompressionLevel.Max, inData, compressedBuffer);
62-
return compressedBuffer;
62+
return [.. compressedBuffer.Take(compressedSize)];
6363
}
6464

6565
private static byte[] CompressLZ4(byte[] inData)

0 commit comments

Comments
 (0)