SHA256
3
0
forked from pool/zlib
zlib/zlib-format.patch
Danilo Spinella 22d97a578b Accepting request 1119078 from home:dspinella:branches:devel:libraries:c_c++
- Update to 1.3:
  * Building using K&R (pre-ANSI) function definitions is no longer supported.
  * Fixed a bug in deflateBound() for level 0 and memLevel 9.
  * Fixed a bug when gzungetc() is used immediately after gzopen().
  * Fixed a bug when using gzflush() with a very small buffer.
  * Fixed a crash when gzsetparams() is attempted for a transparent write.
  * Fixed test/example.c to work with FORCE_STORED.
  * Fixed minizip to allow it to open an empty zip file.
  * Fixed reading disk number start on zip64 files in minizip.
  * Fixed a logic error in minizip argument processing. 
- Added patches:
  * zlib-1.3-IBM-Z-hw-accelerated-deflate-s390x.patch
- Refreshed patches:
  * zlib-1.2.12-add-optimized-slide_hash-for-power.patch
  * zlib-1.2.12-add-vectorized-longest_match-for-power.patch
  * zlib-1.2.12-adler32-vector-optimizations-for-power.patch
  * zlib-1.2.13-optimized-s390.patch
  * zlib-format.patch
  * zlib-no-version-check.patch
- Removed patches:
  * bsc1210593.patch
  * zlib-1.2.13-fix-bug-deflateBound.patch
  * zlib-1.2.12-s390-vectorize-crc32.patch
  * zlib-1.2.13-IBM-Z-hw-accelerated-deflate-s390x.patch
  * zlib-1.2.12-add-optimized-slide_hash-for-power.patch
  * zlib-1.2.12-fix-invalid-memory-access-on-ppc-and-ppc64.patch
  * zlib-1.2.12-add-vectorized-longest_match-for-power.patch
  * zlib-1.2.12-adler32-vector-optimizations-for-power.patch
- Fix CVE-2023-45853, integer overflow and resultant heap-based buffer
  overflow in zipOpenNewFileInZip4_6, bsc#1216378

OBS-URL: https://build.opensuse.org/request/show/1119078
OBS-URL: https://build.opensuse.org/package/show/devel:libraries:c_c++/zlib?expand=0&rev=95
2023-10-19 16:28:40 +00:00

21 lines
691 B
Diff

From: meissner@suse.de
Subject: supply format arguments to gzprintf().
Index: zlib.h
===================================================================
--- zlib.h.orig
+++ zlib.h
@@ -1465,7 +1465,11 @@ ZEXTERN z_size_t ZEXPORT gzfwrite OF((vo
is returned, and the error state is set to Z_STREAM_ERROR.
*/
-ZEXTERN int ZEXPORTVA gzprintf(gzFile file, const char *format, ...);
+ZEXTERN int ZEXPORTVA gzprintf(gzFile file, const char *format, ...)
+#ifdef __GNUC__
+ __attribute__((__format__(__printf__,2,3)))
+#endif
+;
/*
Convert, format, compress, and write the arguments (...) to file under
control of the string format, as in fprintf. gzprintf returns the number of