diff --git a/src/SharpCompress/Compressors/Rar/UnpackV1/Unpack.cs b/src/SharpCompress/Compressors/Rar/UnpackV1/Unpack.cs index c62d5906..732c57e8 100644 --- a/src/SharpCompress/Compressors/Rar/UnpackV1/Unpack.cs +++ b/src/SharpCompress/Compressors/Rar/UnpackV1/Unpack.cs @@ -263,7 +263,7 @@ internal sealed partial class Unpack : BitInput, IRarUnpack, IDisposable if (((wrPtr - unpPtr) & PackDef.MAXWINMASK) < 260 && wrPtr != unpPtr) { UnpWriteBuf(); - if (destUnpSize <= 0) + if (destUnpSize < 0) { return; } @@ -713,7 +713,7 @@ internal sealed partial class Unpack : BitInput, IRarUnpack, IDisposable private void UnpWriteData(byte[] data, int offset, int size) { - if (destUnpSize <= 0) + if (destUnpSize < 0) { return; }