diff --git a/SevenZip/StreamWrappers.cs b/SevenZip/StreamWrappers.cs index 1f35f3c..662862e 100644 --- a/SevenZip/StreamWrappers.cs +++ b/SevenZip/StreamWrappers.cs @@ -415,7 +415,7 @@ public int Write(byte[] data, uint size, IntPtr processedSize) int offset = 0; var originalSize = (int) size; Position += size; - _overallLength = Math.Max(Position + 1, _overallLength); + _overallLength = Math.Max(Position, _overallLength); while (size > _volumeSize - Streams[CurrentStream].Position) { var count = (int) (_volumeSize - Streams[CurrentStream].Position); @@ -493,4 +493,4 @@ private void OnBytesWritten(IntEventArgs e) } } #endif -} \ No newline at end of file +}