summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorOndrej Tethal <ondrej.tethal@oracle.com>2022-12-09 10:21:58 +0100
committerOndrej Tethal <ondrej.tethal@oracle.com>2022-12-09 10:21:58 +0100
commitb6faecc46fcc4f6412149f2021447c0070eba60e (patch)
treee5f455152df99e76626f55e584e2ff12b045e466
parent49c3178711ddb3510f0e96297187f823cc019871 (diff)
downloadgitdb-b6faecc46fcc4f6412149f2021447c0070eba60e.tar.gz
Use ZLIB_RUNTIME_VERSION if available
-rw-r--r--gitdb/stream.py2
1 files changed, 1 insertions, 1 deletions
diff --git a/gitdb/stream.py b/gitdb/stream.py
index 222b843..1b5426f 100644
--- a/gitdb/stream.py
+++ b/gitdb/stream.py
@@ -294,7 +294,7 @@ class DecompressMemMapReader(LazyMixin):
# However, the zlib VERSIONs as well as the platform check is used to further match the entries in the
# table in the github issue. This is it ... it was the only way I could make this work everywhere.
# IT's CERTAINLY GOING TO BITE US IN THE FUTURE ... .
- if zlib.ZLIB_VERSION in ('1.2.7', '1.2.5') and not sys.platform == 'darwin':
+ if getattr(zlib, 'ZLIB_RUNTIME_VERSION', zlib.ZLIB_VERSION) in ('1.2.7', '1.2.5') and not sys.platform == 'darwin':
unused_datalen = len(self._zip.unconsumed_tail)
else:
unused_datalen = len(self._zip.unconsumed_tail) + len(self._zip.unused_data)