solve edge case
This commit is contained in:
parent
741d34a5e0
commit
0472bfe58e
15 changed files with 685 additions and 47 deletions
|
|
@ -71,7 +71,7 @@ public class PngPipeEncoder : IDisposable
|
|||
_zlibStream.Write(buffer.Span.Slice(offset, FlushThreshold));
|
||||
await _zlibStream.FlushAsync(cancellationToken);
|
||||
offset += FlushThreshold;
|
||||
if(_outputPipe.UnflushedBytes >= PipeChunkThreshold)
|
||||
if(_memoryStream.Length >= BufferSize)
|
||||
await FlushAsync(cancellationToken);
|
||||
}
|
||||
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue