Script 'mail_helper' called by obssrc
Hello community,
here is the log from the commit of package zlib-ng for openSUSE:Factory checked in at 2022-12-24 14:52:13
++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++
Comparing /work/SRC/openSUSE:Factory/zlib-ng (Old)
and /work/SRC/openSUSE:Factory/.zlib-ng.new.1563 (New)
++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++
Package is "zlib-ng"
Sat Dec 24 14:52:13 2022 rev:9 rq:1045106 version:2.0.6
Changes:
--------
--- /work/SRC/openSUSE:Factory/zlib-ng/zlib-ng.changes 2022-12-12 17:42:08.061939676 +0100
+++ /work/SRC/openSUSE:Factory/.zlib-ng.new.1563/zlib-ng.changes 2022-12-24 14:55:07.572623959 +0100
@@ -1,0 +2,6 @@
+Thu Dec 22 13:22:08 UTC 2022 - Dirk M��ller
+
+- add 0001-Add-one-extra-byte-to-return-value-of-compressBound-.patch
+ fixes a data corruption regression in 2.0.6
+
+-------------------------------------------------------------------
New:
----
0001-Add-one-extra-byte-to-return-value-of-compressBound-.patch
++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++
Other differences:
------------------
++++++ zlib-ng.spec ++++++
--- /var/tmp/diff_new_pack.KxxJkN/_old 2022-12-24 14:55:07.984626363 +0100
+++ /var/tmp/diff_new_pack.KxxJkN/_new 2022-12-24 14:55:07.988626386 +0100
@@ -42,6 +42,8 @@
Source1: baselibs.conf
# PATCH-FIX-UPSTREAM - Backport https://github.com/zlib-ng/zlib-ng/pull/1297 to fix boo#1200578
Patch0: 1297.patch
+# Cherry-pick bisected from develop branch
+Patch1: 0001-Add-one-extra-byte-to-return-value-of-compressBound-.patch
BuildRequires: cmake
BuildRequires: gcc
%if %{with systemtap}
++++++ 0001-Add-one-extra-byte-to-return-value-of-compressBound-.patch ++++++
From 4fadf3c49e3dc98c5e1c0b86401324061d951d9f Mon Sep 17 00:00:00 2001
From: Mika Lindqvist
Date: Wed, 6 Apr 2022 00:04:45 +0300
Subject: [PATCH] Add one extra byte to return value of compressBound and
deflateBound for small lengths due to shift returning 0. * Treat 0 byte input
as 1 byte input when calculating compressBound and deflateBound
---
compress.c | 2 ++
deflate.c | 2 ++
2 files changed, 4 insertions(+)
diff --git a/compress.c b/compress.c
index db13f6c..44f8dd9 100644
--- a/compress.c
+++ b/compress.c
@@ -87,6 +87,8 @@ z_size_t Z_EXPORT PREFIX(compressBound)(z_size_t sourceLen) {
#ifndef NO_QUICK_STRATEGY
return sourceLen /* The source size itself */
+ + (sourceLen == 0 ? 1 : 0) /* Always at least one byte for any input */
+ + (sourceLen < 9 ? 1 : 0) /* One extra byte for lengths less than 9 */
+ DEFLATE_QUICK_OVERHEAD(sourceLen) /* Source encoding overhead, padded to next full byte */
+ DEFLATE_BLOCK_OVERHEAD /* Deflate block overhead bytes */
+ ZLIB_WRAPLEN; /* zlib wrapper */
diff --git a/deflate.c b/deflate.c
index 50c5531..233a629 100644
--- a/deflate.c
+++ b/deflate.c
@@ -646,6 +646,8 @@ unsigned long Z_EXPORT PREFIX(deflateBound)(PREFIX3(stream) *strm, unsigned long
#ifndef NO_QUICK_STRATEGY
return sourceLen /* The source size itself */
+ + (sourceLen == 0 ? 1 : 0) /* Always at least one byte for any input */
+ + (sourceLen < 9 ? 1 : 0) /* One extra byte for lengths less than 9 */
+ DEFLATE_QUICK_OVERHEAD(sourceLen) /* Source encoding overhead, padded to next full byte */
+ DEFLATE_BLOCK_OVERHEAD /* Deflate block overhead bytes */
+ wraplen; /* none, zlib or gzip wrapper */
--
2.39.0