summaryrefslogtreecommitdiffstatshomepage
path: root/3rdparty/zlib/contrib/infback9
diff options
context:
space:
mode:
Diffstat (limited to '3rdparty/zlib/contrib/infback9')
-rw-r--r--3rdparty/zlib/contrib/infback9/infback9.c24
-rw-r--r--3rdparty/zlib/contrib/infback9/infback9.h16
-rw-r--r--3rdparty/zlib/contrib/infback9/inftree9.c17
-rw-r--r--3rdparty/zlib/contrib/infback9/inftree9.h12
4 files changed, 26 insertions, 43 deletions
diff --git a/3rdparty/zlib/contrib/infback9/infback9.c b/3rdparty/zlib/contrib/infback9/infback9.c
index 05fb3e33807..742a39214ab 100644
--- a/3rdparty/zlib/contrib/infback9/infback9.c
+++ b/3rdparty/zlib/contrib/infback9/infback9.c
@@ -16,12 +16,8 @@
window is a user-supplied window and output buffer that is 64K bytes.
*/
-int ZEXPORT inflateBack9Init_(strm, window, version, stream_size)
-z_stream FAR *strm;
-unsigned char FAR *window;
-const char *version;
-int stream_size;
-{
+int ZEXPORT inflateBack9Init_(z_stream FAR *strm, unsigned char FAR *window,
+ const char *version, int stream_size) {
struct inflate_state FAR *state;
if (version == Z_NULL || version[0] != ZLIB_VERSION[0] ||
@@ -51,8 +47,7 @@ int stream_size;
#ifdef MAKEFIXED
#include <stdio.h>
-void makefixed9(void)
-{
+void makefixed9(void) {
unsigned sym, bits, low, size;
code *next, *lenfix, *distfix;
struct inflate_state state;
@@ -214,13 +209,8 @@ void makefixed9(void)
inflateBack() can also return Z_STREAM_ERROR if the input parameters
are not correct, i.e. strm is Z_NULL or the state was not initialized.
*/
-int ZEXPORT inflateBack9(strm, in, in_desc, out, out_desc)
-z_stream FAR *strm;
-in_func in;
-void FAR *in_desc;
-out_func out;
-void FAR *out_desc;
-{
+int ZEXPORT inflateBack9(z_stream FAR *strm, in_func in, void FAR *in_desc,
+ out_func out, void FAR *out_desc) {
struct inflate_state FAR *state;
z_const unsigned char FAR *next; /* next input */
unsigned char FAR *put; /* next output */
@@ -603,9 +593,7 @@ void FAR *out_desc;
return ret;
}
-int ZEXPORT inflateBack9End(strm)
-z_stream FAR *strm;
-{
+int ZEXPORT inflateBack9End(z_stream FAR *strm) {
if (strm == Z_NULL || strm->state == Z_NULL || strm->zfree == (free_func)0)
return Z_STREAM_ERROR;
ZFREE(strm, strm->state);
diff --git a/3rdparty/zlib/contrib/infback9/infback9.h b/3rdparty/zlib/contrib/infback9/infback9.h
index 1073c0a38e6..8371b4ec7d2 100644
--- a/3rdparty/zlib/contrib/infback9/infback9.h
+++ b/3rdparty/zlib/contrib/infback9/infback9.h
@@ -20,14 +20,14 @@
extern "C" {
#endif
-ZEXTERN int ZEXPORT inflateBack9 OF((z_stream FAR *strm,
- in_func in, void FAR *in_desc,
- out_func out, void FAR *out_desc));
-ZEXTERN int ZEXPORT inflateBack9End OF((z_stream FAR *strm));
-ZEXTERN int ZEXPORT inflateBack9Init_ OF((z_stream FAR *strm,
- unsigned char FAR *window,
- const char *version,
- int stream_size));
+ZEXTERN int ZEXPORT inflateBack9(z_stream FAR *strm,
+ in_func in, void FAR *in_desc,
+ out_func out, void FAR *out_desc);
+ZEXTERN int ZEXPORT inflateBack9End(z_stream FAR *strm);
+ZEXTERN int ZEXPORT inflateBack9Init_(z_stream FAR *strm,
+ unsigned char FAR *window,
+ const char *version,
+ int stream_size);
#define inflateBack9Init(strm, window) \
inflateBack9Init_((strm), (window), \
ZLIB_VERSION, sizeof(z_stream))
diff --git a/3rdparty/zlib/contrib/infback9/inftree9.c b/3rdparty/zlib/contrib/infback9/inftree9.c
index 5f4a76798d8..ac707ed3fbd 100644
--- a/3rdparty/zlib/contrib/infback9/inftree9.c
+++ b/3rdparty/zlib/contrib/infback9/inftree9.c
@@ -1,5 +1,5 @@
/* inftree9.c -- generate Huffman trees for efficient decoding
- * Copyright (C) 1995-2017 Mark Adler
+ * Copyright (C) 1995-2024 Mark Adler
* For conditions of distribution and use, see copyright notice in zlib.h
*/
@@ -9,7 +9,7 @@
#define MAXBITS 15
const char inflate9_copyright[] =
- " inflate9 1.2.11 Copyright 1995-2017 Mark Adler ";
+ " inflate9 1.3.1 Copyright 1995-2024 Mark Adler ";
/*
If you use the zlib library in a product, an acknowledgment is welcome
in the documentation of your product. If for some reason you cannot
@@ -29,14 +29,9 @@ const char inflate9_copyright[] =
table index bits. It will differ if the request is greater than the
longest code or if it is less than the shortest code.
*/
-int inflate_table9(type, lens, codes, table, bits, work)
-codetype type;
-unsigned short FAR *lens;
-unsigned codes;
-code FAR * FAR *table;
-unsigned FAR *bits;
-unsigned short FAR *work;
-{
+int inflate_table9(codetype type, unsigned short FAR *lens, unsigned codes,
+ code FAR * FAR *table, unsigned FAR *bits,
+ unsigned short FAR *work) {
unsigned len; /* a code's length in bits */
unsigned sym; /* index of code symbols */
unsigned min, max; /* minimum and maximum code lengths */
@@ -64,7 +59,7 @@ unsigned short FAR *work;
static const unsigned short lext[31] = { /* Length codes 257..285 extra */
128, 128, 128, 128, 128, 128, 128, 128, 129, 129, 129, 129,
130, 130, 130, 130, 131, 131, 131, 131, 132, 132, 132, 132,
- 133, 133, 133, 133, 144, 77, 202};
+ 133, 133, 133, 133, 144, 203, 77};
static const unsigned short dbase[32] = { /* Distance codes 0..31 base */
1, 2, 3, 4, 5, 7, 9, 13, 17, 25, 33, 49,
65, 97, 129, 193, 257, 385, 513, 769, 1025, 1537, 2049, 3073,
diff --git a/3rdparty/zlib/contrib/infback9/inftree9.h b/3rdparty/zlib/contrib/infback9/inftree9.h
index 5ab21f0c6d1..ab2ea28b2ba 100644
--- a/3rdparty/zlib/contrib/infback9/inftree9.h
+++ b/3rdparty/zlib/contrib/infback9/inftree9.h
@@ -38,11 +38,11 @@ typedef struct {
/* Maximum size of the dynamic table. The maximum number of code structures is
1446, which is the sum of 852 for literal/length codes and 594 for distance
codes. These values were found by exhaustive searches using the program
- examples/enough.c found in the zlib distribtution. The arguments to that
+ examples/enough.c found in the zlib distribution. The arguments to that
program are the number of symbols, the initial root table size, and the
maximum bit length of a code. "enough 286 9 15" for literal/length codes
- returns returns 852, and "enough 32 6 15" for distance codes returns 594.
- The initial root table size (9 or 6) is found in the fifth argument of the
+ returns 852, and "enough 32 6 15" for distance codes returns 594. The
+ initial root table size (9 or 6) is found in the fifth argument of the
inflate_table() calls in infback9.c. If the root table size is changed,
then these maximum sizes would be need to be recalculated and updated. */
#define ENOUGH_LENS 852
@@ -56,6 +56,6 @@ typedef enum {
DISTS
} codetype;
-extern int inflate_table9 OF((codetype type, unsigned short FAR *lens,
- unsigned codes, code FAR * FAR *table,
- unsigned FAR *bits, unsigned short FAR *work));
+extern int inflate_table9(codetype type, unsigned short FAR *lens,
+ unsigned codes, code FAR * FAR *table,
+ unsigned FAR *bits, unsigned short FAR *work);