summaryrefslogtreecommitdiffstats
path: root/Doc/library/zlib.rst
diff options
context:
space:
mode:
authorNadeem Vawda <nadeem.vawda@gmail.com>2012-11-11 13:04:14 (GMT)
committerNadeem Vawda <nadeem.vawda@gmail.com>2012-11-11 13:04:14 (GMT)
commit19e568d254bea8202703302d0ada9bc93f99331a (patch)
tree74dfb24f4c4a14b1f4ed963a22df688bc1f13abc /Doc/library/zlib.rst
parent12489d98e692717a93694644dac4975d54106178 (diff)
downloadcpython-19e568d254bea8202703302d0ada9bc93f99331a.zip
cpython-19e568d254bea8202703302d0ada9bc93f99331a.tar.gz
cpython-19e568d254bea8202703302d0ada9bc93f99331a.tar.bz2
Issue #15677: Document that zlib and gzip accept a compression level of 0 to mean 'no compression'.
Patch by Brian Brazil.
Diffstat (limited to 'Doc/library/zlib.rst')
-rw-r--r--Doc/library/zlib.rst15
1 files changed, 8 insertions, 7 deletions
diff --git a/Doc/library/zlib.rst b/Doc/library/zlib.rst
index 897d919..75640d4 100644
--- a/Doc/library/zlib.rst
+++ b/Doc/library/zlib.rst
@@ -51,19 +51,20 @@ The available exception and functions in this module are:
.. function:: compress(data[, level])
- Compresses the bytes in *data*, returning a bytes object containing compressed data.
- *level* is an integer from ``1`` to ``9`` controlling the level of compression;
- ``1`` is fastest and produces the least compression, ``9`` is slowest and
- produces the most. The default value is ``6``. Raises the :exc:`error`
- exception if any error occurs.
+ Compresses the bytes in *data*, returning a bytes object containing
+ compressed data. *level* is an integer from ``0`` to ``9`` controlling the
+ level of compression; ``1`` is fastest and produces the least compression,
+ ``9`` is slowest and produces the most. ``0`` is no compression. The default
+ value is ``6``. Raises the :exc:`error` exception if any error occurs.
.. function:: compressobj([level])
Returns a compression object, to be used for compressing data streams that won't
- fit into memory at once. *level* is an integer from ``1`` to ``9`` controlling
+ fit into memory at once. *level* is an integer from ``0`` to ``9`` controlling
the level of compression; ``1`` is fastest and produces the least compression,
- ``9`` is slowest and produces the most. The default value is ``6``.
+ ``9`` is slowest and produces the most. ``0`` is no compression. The default
+ value is ``6``.
.. function:: crc32(data[, value])