From a7af2a6f001a4bca7708a9a26c56e742b26ac375 Mon Sep 17 00:00:00 2001 From: Stefan-Alin Pahontu <56953855+alinpahontu2912@users.noreply.github.com> Date: Wed, 3 Sep 2025 16:40:53 +0200 Subject: [PATCH 1/2] add remark about different byte sequence --- xml/System.IO.Compression/DeflateStream.xml | 2 ++ 1 file changed, 2 insertions(+) diff --git a/xml/System.IO.Compression/DeflateStream.xml b/xml/System.IO.Compression/DeflateStream.xml index f53e383ae04..f2af620a98c 100644 --- a/xml/System.IO.Compression/DeflateStream.xml +++ b/xml/System.IO.Compression/DeflateStream.xml @@ -64,6 +64,8 @@ The class uses the same compression a The compression functionality in and is exposed as a stream. Data is read on a byte-by-byte basis, so it is not possible to perform multiple passes to determine the best method for compressing entire files or large blocks of data. The and classes are best used on uncompressed sources of data. If the source data is already compressed, using these classes may actually increase the size of the stream. +The exact compressed byte sequence returned by can vary between .NET releases, platforms, or underlying compression engines, as changes in zlib versions, algorithm tweaks, or performance optimizations may produce different outputs for the same input data, but any data compressed by DeflateStream can always be decompressed to its original form without loss. + ## Examples The following example shows how to use the class to compress and decompress a file. From cd51d8823192d5d76b86d59af9332a301ae7ef29 Mon Sep 17 00:00:00 2001 From: Stefan-Alin Pahontu <56953855+alinpahontu2912@users.noreply.github.com> Date: Thu, 4 Sep 2025 11:12:06 +0200 Subject: [PATCH 2/2] commit suggeestion Co-authored-by: Genevieve Warren <24882762+gewarren@users.noreply.github.com> --- xml/System.IO.Compression/DeflateStream.xml | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/xml/System.IO.Compression/DeflateStream.xml b/xml/System.IO.Compression/DeflateStream.xml index f2af620a98c..ecb60f39935 100644 --- a/xml/System.IO.Compression/DeflateStream.xml +++ b/xml/System.IO.Compression/DeflateStream.xml @@ -64,7 +64,7 @@ The class uses the same compression a The compression functionality in and is exposed as a stream. Data is read on a byte-by-byte basis, so it is not possible to perform multiple passes to determine the best method for compressing entire files or large blocks of data. The and classes are best used on uncompressed sources of data. If the source data is already compressed, using these classes may actually increase the size of the stream. -The exact compressed byte sequence returned by can vary between .NET releases, platforms, or underlying compression engines, as changes in zlib versions, algorithm tweaks, or performance optimizations may produce different outputs for the same input data, but any data compressed by DeflateStream can always be decompressed to its original form without loss. +The exact compressed byte sequence returned by can vary between .NET releases, platforms, and underlying compression engines. Changes in zlib versions, algorithm tweaks, and performance optimizations might produce different outputs for the same input data. But any data compressed by `DeflateStream` can always be decompressed to its original form without loss. ## Examples