3 # Patch managed by http://www.holgerschurig.de/patcher.html
6 --- zlib-1.2.3-orig/adler32.c~visibility
7 +++ zlib-1.2.3-orig/adler32.c
11 /* ========================================================================= */
12 -uLong ZEXPORT adler32(adler, buf, len)
13 +ZEXPORT uLong adler32(adler, buf, len)
17 --- zlib-1.2.3-orig/compress.c~visibility
18 +++ zlib-1.2.3-orig/compress.c
20 memory, Z_BUF_ERROR if there was not enough room in the output buffer,
21 Z_STREAM_ERROR if the level parameter is invalid.
23 -int ZEXPORT compress2 (dest, destLen, source, sourceLen, level)
24 +ZEXPORT int compress2 (dest, destLen, source, sourceLen, level)
30 /* ===========================================================================
32 -int ZEXPORT compress (dest, destLen, source, sourceLen)
33 +ZEXPORT int compress (dest, destLen, source, sourceLen)
38 If the default memLevel or windowBits for deflateInit() is changed, then
39 this function needs to be updated.
41 -uLong ZEXPORT compressBound (sourceLen)
42 +ZEXPORT uLong compressBound (sourceLen)
45 return sourceLen + (sourceLen >> 12) + (sourceLen >> 14) + 11;
46 --- zlib-1.2.3-orig/crc32.c~visibility
47 +++ zlib-1.2.3-orig/crc32.c
49 /* =========================================================================
50 * This function can be used by asm versions of crc32()
52 -const unsigned long FAR * ZEXPORT get_crc_table()
53 +ZEXPORT const unsigned long FAR * get_crc_table()
55 #ifdef DYNAMIC_CRC_TABLE
58 #define DO8 DO1; DO1; DO1; DO1; DO1; DO1; DO1; DO1
60 /* ========================================================================= */
61 -unsigned long ZEXPORT crc32(crc, buf, len)
62 +ZEXPORT unsigned long crc32(crc, buf, len)
64 const unsigned char FAR *buf;
66 --- zlib-1.2.3-orig/deflate.c~visibility
67 +++ zlib-1.2.3-orig/deflate.c
69 zmemzero((Bytef *)s->head, (unsigned)(s->hash_size-1)*sizeof(*s->head));
71 /* ========================================================================= */
72 -int ZEXPORT deflateInit_(strm, level, version, stream_size)
73 +ZEXPORT int deflateInit_(strm, level, version, stream_size)
80 /* ========================================================================= */
81 -int ZEXPORT deflateInit2_(strm, level, method, windowBits, memLevel, strategy,
82 +ZEXPORT int deflateInit2_(strm, level, method, windowBits, memLevel, strategy,
89 /* ========================================================================= */
90 -int ZEXPORT deflateSetDictionary (strm, dictionary, dictLength)
91 +ZEXPORT int deflateSetDictionary (strm, dictionary, dictLength)
93 const Bytef *dictionary;
98 /* ========================================================================= */
99 -int ZEXPORT deflateReset (strm)
100 +ZEXPORT int deflateReset (strm)
107 /* ========================================================================= */
108 -int ZEXPORT deflatePrime (strm, bits, value)
109 +ZEXPORT int deflatePrime (strm, bits, value)
116 /* ========================================================================= */
117 -int ZEXPORT deflateParams(strm, level, strategy)
118 +ZEXPORT int deflateParams(strm, level, strategy)
123 * But even the conservative upper bound of about 14% expansion does not
124 * seem onerous for output buffer allocation.
126 -uLong ZEXPORT deflateBound(strm, sourceLen)
127 +ZEXPORT uLong deflateBound(strm, sourceLen)
134 /* ========================================================================= */
135 -int ZEXPORT deflate (strm, flush)
136 +ZEXPORT int deflate (strm, flush)
143 /* ========================================================================= */
144 -int ZEXPORT deflateEnd (strm)
145 +ZEXPORT int deflateEnd (strm)
150 * To simplify the source, this is not supported for 16-bit MSDOS (which
151 * doesn't have enough memory anyway to duplicate compression states).
153 -int ZEXPORT deflateCopy (dest, source)
154 +ZEXPORT int deflateCopy (dest, source)
158 --- zlib-1.2.3-orig/gzio.c~visibility
159 +++ zlib-1.2.3-orig/gzio.c
161 /* ===========================================================================
162 Opens a gzip (.gz) file for reading or writing.
164 -gzFile ZEXPORT gzopen (path, mode)
165 +ZEXPORT gzFile gzopen (path, mode)
170 Associate a gzFile with the file descriptor fd. fd is not dup'ed here
171 to mimic the behavio(u)r of fdopen.
173 -gzFile ZEXPORT gzdopen (fd, mode)
174 +ZEXPORT gzFile gzdopen (fd, mode)
179 /* ===========================================================================
180 * Update the compression level and strategy
182 -int ZEXPORT gzsetparams (file, level, strategy)
183 +ZEXPORT int gzsetparams (file, level, strategy)
188 Reads the given number of uncompressed bytes from the compressed file.
189 gzread returns the number of bytes actually read (0 for end of file).
191 -int ZEXPORT gzread (file, buf, len)
192 +ZEXPORT int gzread (file, buf, len)
197 Reads one byte from the compressed file. gzgetc returns this byte
198 or -1 in case of end of file or error.
200 -int ZEXPORT gzgetc(file)
201 +ZEXPORT int gzgetc(file)
206 /* ===========================================================================
207 Push one byte back onto the stream.
209 -int ZEXPORT gzungetc(c, file)
210 +ZEXPORT int gzungetc(c, file)
216 The current implementation is not optimized at all.
218 -char * ZEXPORT gzgets(file, buf, len)
219 +ZEXPORT char * gzgets(file, buf, len)
224 Writes the given number of uncompressed bytes into the compressed file.
225 gzwrite returns the number of bytes actually written (0 in case of error).
227 -int ZEXPORT gzwrite (file, buf, len)
228 +ZEXPORT int gzwrite (file, buf, len)
236 -int ZEXPORTVA gzprintf (gzFile file, const char *format, /* args */ ...)
237 +ZEXPORTVA int gzprintf (gzFile file, const char *format, /* args */ ...)
239 char buf[Z_PRINTF_BUFSIZE];
243 #else /* not ANSI C */
245 -int ZEXPORTVA gzprintf (file, format, a1, a2, a3, a4, a5, a6, a7, a8, a9, a10,
246 +ZEXPORT intVA gzprintf (file, format, a1, a2, a3, a4, a5, a6, a7, a8, a9, a10,
247 a11, a12, a13, a14, a15, a16, a17, a18, a19, a20)
251 Writes c, converted to an unsigned char, into the compressed file.
252 gzputc returns the value that was written, or -1 in case of error.
254 -int ZEXPORT gzputc(file, c)
255 +ZEXPORT int gzputc(file, c)
260 the terminating null character.
261 gzputs returns the number of characters written, or -1 in case of error.
263 -int ZEXPORT gzputs(file, s)
264 +ZEXPORT int gzputs(file, s)
269 return s->z_err == Z_STREAM_END ? Z_OK : s->z_err;
272 -int ZEXPORT gzflush (file, flush)
273 +ZEXPORT int gzflush (file, flush)
278 SEEK_END is not implemented, returns error.
279 In this version of the library, gzseek can be extremely slow.
281 -z_off_t ZEXPORT gzseek (file, offset, whence)
282 +ZEXPORT z_off_t gzseek (file, offset, whence)
287 /* ===========================================================================
290 -int ZEXPORT gzrewind (file)
291 +ZEXPORT int gzrewind (file)
294 gz_stream *s = (gz_stream*)file;
296 given compressed file. This position represents a number of bytes in the
297 uncompressed data stream.
299 -z_off_t ZEXPORT gztell (file)
300 +ZEXPORT z_off_t gztell (file)
303 return gzseek(file, 0L, SEEK_CUR);
305 Returns 1 when EOF has previously been detected reading the given
306 input stream, otherwise zero.
308 -int ZEXPORT gzeof (file)
309 +ZEXPORT int gzeof (file)
312 gz_stream *s = (gz_stream*)file;
314 Flushes all pending output if necessary, closes the compressed file
315 and deallocates all the (de)compression state.
317 -int ZEXPORT gzclose (file)
318 +ZEXPORT int gzclose (file)
321 gz_stream *s = (gz_stream*)file;
323 errnum is set to Z_ERRNO and the application may consult errno
324 to get the exact error code.
326 -const char * ZEXPORT gzerror (file, errnum)
327 +ZEXPORT const char * gzerror (file, errnum)
331 @@ -1014,7 +1014,7 @@
332 /* ===========================================================================
333 Clear the error and end-of-file flags, and do the same for the real file.
335 -void ZEXPORT gzclearerr (file)
336 +ZEXPORT void gzclearerr (file)
339 gz_stream *s = (gz_stream*)file;
340 --- zlib-1.2.3-orig/infback.c~visibility
341 +++ zlib-1.2.3-orig/infback.c
343 windowBits is in the range 8..15, and window is a user-supplied
344 window and output buffer that is 2**windowBits bytes.
346 -int ZEXPORT inflateBackInit_(strm, windowBits, window, version, stream_size)
347 +ZEXPORT int inflateBackInit_(strm, windowBits, window, version, stream_size)
350 unsigned char FAR *window;
352 inflateBack() can also return Z_STREAM_ERROR if the input parameters
353 are not correct, i.e. strm is Z_NULL or the state was not initialized.
355 -int ZEXPORT inflateBack(strm, in, in_desc, out, out_desc)
356 +ZEXPORT int inflateBack(strm, in, in_desc, out, out_desc)
364 -int ZEXPORT inflateBackEnd(strm)
365 +ZEXPORT int inflateBackEnd(strm)
368 if (strm == Z_NULL || strm->state == Z_NULL || strm->zfree == (free_func)0)
369 --- zlib-1.2.3-orig/inflate.c~visibility
370 +++ zlib-1.2.3-orig/inflate.c
372 local unsigned syncsearch OF((unsigned FAR *have, unsigned char FAR *buf,
375 -int ZEXPORT inflateReset(strm)
376 +ZEXPORT int inflateReset(strm)
379 struct inflate_state FAR *state;
384 -int ZEXPORT inflateInit2_(strm, windowBits, version, stream_size)
385 +ZEXPORT int inflateInit2_(strm, windowBits, version, stream_size)
390 return inflateReset(strm);
393 -int ZEXPORT inflateInit_(strm, version, stream_size)
394 +ZEXPORT int inflateInit_(strm, version, stream_size)
399 will return Z_BUF_ERROR if it has not reached the end of the stream.
402 -int ZEXPORT inflate(strm, flush)
403 +ZEXPORT int inflate(strm, flush)
407 @@ -1152,7 +1152,7 @@
411 -int ZEXPORT inflateEnd(strm)
412 +ZEXPORT int inflateEnd(strm)
415 struct inflate_state FAR *state;
416 @@ -1166,7 +1166,7 @@
420 -int ZEXPORT inflateSetDictionary(strm, dictionary, dictLength)
421 +ZEXPORT int inflateSetDictionary(strm, dictionary, dictLength)
423 const Bytef *dictionary;
425 @@ -1259,7 +1259,7 @@
429 -int ZEXPORT inflateSync(strm)
430 +ZEXPORT int inflateSync(strm)
433 unsigned len; /* number of bytes to look at or looked at */
434 @@ -1310,7 +1310,7 @@
435 block. When decompressing, PPP checks that at the end of input packet,
436 inflate is waiting for these length bytes.
438 -int ZEXPORT inflateSyncPoint(strm)
439 +ZEXPORT int inflateSyncPoint(strm)
442 struct inflate_state FAR *state;
443 @@ -1320,7 +1320,7 @@
444 return state->mode == STORED && state->bits == 0;
447 -int ZEXPORT inflateCopy(dest, source)
448 +ZEXPORT int inflateCopy(dest, source)
452 --- zlib-1.2.3-orig/uncompr.c~visibility
453 +++ zlib-1.2.3-orig/uncompr.c
455 enough memory, Z_BUF_ERROR if there was not enough room in the output
456 buffer, or Z_DATA_ERROR if the input data was corrupted.
458 -int ZEXPORT uncompress (dest, destLen, source, sourceLen)
459 +ZEXPORT int uncompress (dest, destLen, source, sourceLen)
463 --- zlib-1.2.3-orig/zconf.in.h~visibility
464 +++ zlib-1.2.3-orig/zconf.in.h
468 # if defined(WIN32) && (!defined(__BORLANDC__) || (__BORLANDC__ >= 0x500))
469 -# ifdef ZLIB_INTERNAL
470 -# define ZEXTERN extern __declspec(dllexport)
472 -# define ZEXTERN extern __declspec(dllimport)
474 +# define ZDLLLOCAL __declspec(dllimport)
475 +# define ZDLLPUBLIC __declspec(dllexport)
476 +# define ZEXTERN extern
478 # endif /* ZLIB_DLL */
479 /* If building or using zlib with the WINAPI/WINAPIV calling convention,
480 @@ -229,30 +227,45 @@
481 # define ZEXPORTVA FAR CDECL
486 -#if defined (__BEOS__)
487 +#elif defined (__BEOS__)
489 -# ifdef ZLIB_INTERNAL
490 -# define ZEXPORT __declspec(dllexport)
491 -# define ZEXPORTVA __declspec(dllexport)
493 -# define ZEXPORT __declspec(dllimport)
494 -# define ZEXPORTVA __declspec(dllimport)
496 +# define ZDLLIMPORT __declspec(dllimport)
497 +# define ZDLLPUBLIC __declspec(dllexport)
502 +# ifdef GCC_HASCLASSVISIBILITY
503 +# define ZDLLLOCAL __attribute__ ((visibility("hidden")))
504 +# define ZDLLPUBLIC __attribute__ ((visibility("default")))
512 # define ZEXTERN extern
519 +#ifdef ZLIB_INTERNAL
525 +# define ZEXPORT ZDLLPUBLIC
528 +# define ZEXPORTVA ZDLLPUBLIC
532 +# define ZEXPORT ZDLLIMPORT
535 +# define ZEXPORTVA ZDLLIMPORT
542 --- zlib-1.2.3-orig/zlib.h~visibility
543 +++ zlib-1.2.3-orig/zlib.h
546 /* basic functions */
548 -ZEXTERN const char * ZEXPORT zlibVersion OF((void));
549 +ZEXTERN ZEXPORT const char * zlibVersion OF((void));
550 /* The application can compare zlibVersion and ZLIB_VERSION for consistency.
551 If the first character differs, the library code actually used is
552 not compatible with the zlib.h header file used by the application.
557 -ZEXTERN int ZEXPORT deflateInit OF((z_streamp strm, int level));
558 +ZEXTERN ZEXPORT int deflateInit OF((z_streamp strm, int level));
560 Initializes the internal stream state for compression. The fields
561 zalloc, zfree and opaque must be initialized before by the caller.
566 -ZEXTERN int ZEXPORT deflate OF((z_streamp strm, int flush));
567 +ZEXTERN ZEXPORT int deflate OF((z_streamp strm, int flush));
569 deflate compresses as much data as possible, and stops when the input
570 buffer becomes empty or the output buffer becomes full. It may introduce some
575 -ZEXTERN int ZEXPORT deflateEnd OF((z_streamp strm));
576 +ZEXTERN ZEXPORT int deflateEnd OF((z_streamp strm));
578 All dynamically allocated data structures for this stream are freed.
579 This function discards any unprocessed input and does not flush any
584 -ZEXTERN int ZEXPORT inflateInit OF((z_streamp strm));
585 +ZEXTERN ZEXPORT int inflateInit OF((z_streamp strm));
587 Initializes the internal stream state for decompression. The fields
588 next_in, avail_in, zalloc, zfree and opaque must be initialized before by
593 -ZEXTERN int ZEXPORT inflate OF((z_streamp strm, int flush));
594 +ZEXTERN ZEXPORT int inflate OF((z_streamp strm, int flush));
596 inflate decompresses as much data as possible, and stops when the input
597 buffer becomes empty or the output buffer becomes full. It may introduce
602 -ZEXTERN int ZEXPORT inflateEnd OF((z_streamp strm));
603 +ZEXTERN ZEXPORT int inflateEnd OF((z_streamp strm));
605 All dynamically allocated data structures for this stream are freed.
606 This function discards any unprocessed input and does not flush any
611 -ZEXTERN int ZEXPORT deflateInit2 OF((z_streamp strm,
612 +ZEXTERN ZEXPORT int deflateInit2 OF((z_streamp strm,
617 not perform any compression: this will be done by deflate().
620 -ZEXTERN int ZEXPORT deflateSetDictionary OF((z_streamp strm,
621 +ZEXTERN ZEXPORT int deflateSetDictionary OF((z_streamp strm,
622 const Bytef *dictionary,
626 perform any compression: this will be done by deflate().
629 -ZEXTERN int ZEXPORT deflateCopy OF((z_streamp dest,
630 +ZEXTERN ZEXPORT int deflateCopy OF((z_streamp dest,
633 Sets the destination stream as a complete copy of the source stream.
638 -ZEXTERN int ZEXPORT deflateReset OF((z_streamp strm));
639 +ZEXTERN ZEXPORT int deflateReset OF((z_streamp strm));
641 This function is equivalent to deflateEnd followed by deflateInit,
642 but does not free and reallocate all the internal compression state.
644 stream state was inconsistent (such as zalloc or state being NULL).
647 -ZEXTERN int ZEXPORT deflateParams OF((z_streamp strm,
648 +ZEXTERN ZEXPORT int deflateParams OF((z_streamp strm,
653 returns Z_OK on success, or Z_STREAM_ERROR for an invalid deflate stream.
656 -ZEXTERN uLong ZEXPORT deflateBound OF((z_streamp strm,
657 +ZEXTERN ZEXPORT uLong deflateBound OF((z_streamp strm,
660 deflateBound() returns an upper bound on the compressed size after
662 for deflation in a single pass, and so would be called before deflate().
665 -ZEXTERN int ZEXPORT deflatePrime OF((z_streamp strm,
666 +ZEXTERN ZEXPORT int deflatePrime OF((z_streamp strm,
674 -ZEXTERN int ZEXPORT inflateInit2 OF((z_streamp strm,
675 +ZEXTERN ZEXPORT int inflateInit2 OF((z_streamp strm,
678 This is another version of inflateInit with an extra parameter. The
680 and avail_out are unchanged.)
683 -ZEXTERN int ZEXPORT inflateSetDictionary OF((z_streamp strm,
684 +ZEXTERN ZEXPORT int inflateSetDictionary OF((z_streamp strm,
685 const Bytef *dictionary,
692 -ZEXTERN int ZEXPORT inflateSync OF((z_streamp strm));
693 +ZEXTERN ZEXPORT int inflateSync OF((z_streamp strm));
695 Skips invalid compressed data until a full flush point (see above the
696 description of deflate with Z_FULL_FLUSH) can be found, or until all
698 until success or end of the input data.
701 -ZEXTERN int ZEXPORT inflateCopy OF((z_streamp dest,
702 +ZEXTERN ZEXPORT int inflateCopy OF((z_streamp dest,
705 Sets the destination stream as a complete copy of the source stream.
710 -ZEXTERN int ZEXPORT inflateReset OF((z_streamp strm));
711 +ZEXTERN ZEXPORT int inflateReset OF((z_streamp strm));
713 This function is equivalent to inflateEnd followed by inflateInit,
714 but does not free and reallocate all the internal decompression state.
719 -ZEXTERN int ZEXPORT inflateBackInit OF((z_streamp strm, int windowBits,
720 +ZEXTERN ZEXPORT int inflateBackInit OF((z_streamp strm, int windowBits,
721 unsigned char FAR *window));
723 Initialize the internal stream state for decompression using inflateBack()
725 typedef unsigned (*in_func) OF((void FAR *, unsigned char FAR * FAR *));
726 typedef int (*out_func) OF((void FAR *, unsigned char FAR *, unsigned));
728 -ZEXTERN int ZEXPORT inflateBack OF((z_streamp strm,
729 +ZEXTERN ZEXPORT int inflateBack OF((z_streamp strm,
730 in_func in, void FAR *in_desc,
731 out_func out, void FAR *out_desc));
734 that inflateBack() cannot return Z_OK.
737 -ZEXTERN int ZEXPORT inflateBackEnd OF((z_streamp strm));
738 +ZEXTERN ZEXPORT int inflateBackEnd OF((z_streamp strm));
740 All memory allocated by inflateBackInit() is freed.
743 state was inconsistent.
746 -ZEXTERN uLong ZEXPORT zlibCompileFlags OF((void));
747 +ZEXTERN ZEXPORT uLong zlibCompileFlags OF((void));
748 /* Return flags indicating compile-time options.
750 Type sizes, two bits each, 00 = 16 bits, 01 = 32, 10 = 64, 11 = other:
751 @@ -1006,7 +1006,7 @@
752 utility functions can easily be modified if you need special options.
755 -ZEXTERN int ZEXPORT compress OF((Bytef *dest, uLongf *destLen,
756 +ZEXTERN ZEXPORT int compress OF((Bytef *dest, uLongf *destLen,
757 const Bytef *source, uLong sourceLen));
759 Compresses the source buffer into the destination buffer. sourceLen is
760 @@ -1021,7 +1021,7 @@
764 -ZEXTERN int ZEXPORT compress2 OF((Bytef *dest, uLongf *destLen,
765 +ZEXTERN ZEXPORT int compress2 OF((Bytef *dest, uLongf *destLen,
766 const Bytef *source, uLong sourceLen,
769 @@ -1037,14 +1037,14 @@
770 Z_STREAM_ERROR if the level parameter is invalid.
773 -ZEXTERN uLong ZEXPORT compressBound OF((uLong sourceLen));
774 +ZEXTERN ZEXPORT uLong compressBound OF((uLong sourceLen));
776 compressBound() returns an upper bound on the compressed size after
777 compress() or compress2() on sourceLen bytes. It would be used before
778 a compress() or compress2() call to allocate the destination buffer.
781 -ZEXTERN int ZEXPORT uncompress OF((Bytef *dest, uLongf *destLen,
782 +ZEXTERN ZEXPORT int uncompress OF((Bytef *dest, uLongf *destLen,
783 const Bytef *source, uLong sourceLen));
785 Decompresses the source buffer into the destination buffer. sourceLen is
786 @@ -1065,7 +1065,7 @@
788 typedef voidp gzFile;
790 -ZEXTERN gzFile ZEXPORT gzopen OF((const char *path, const char *mode));
791 +ZEXTERN ZEXPORT gzFile gzopen OF((const char *path, const char *mode));
793 Opens a gzip (.gz) file for reading or writing. The mode parameter
794 is as in fopen ("rb" or "wb") but can also include a compression level
795 @@ -1082,7 +1082,7 @@
796 can be checked to distinguish the two cases (if errno is zero, the
797 zlib error is Z_MEM_ERROR). */
799 -ZEXTERN gzFile ZEXPORT gzdopen OF((int fd, const char *mode));
800 +ZEXTERN ZEXPORT gzFile gzdopen OF((int fd, const char *mode));
802 gzdopen() associates a gzFile with the file descriptor fd. File
803 descriptors are obtained from calls like open, dup, creat, pipe or
804 @@ -1095,7 +1095,7 @@
805 the (de)compression state.
808 -ZEXTERN int ZEXPORT gzsetparams OF((gzFile file, int level, int strategy));
809 +ZEXTERN ZEXPORT int gzsetparams OF((gzFile file, int level, int strategy));
811 Dynamically update the compression level or strategy. See the description
812 of deflateInit2 for the meaning of these parameters.
813 @@ -1103,7 +1103,7 @@
817 -ZEXTERN int ZEXPORT gzread OF((gzFile file, voidp buf, unsigned len));
818 +ZEXTERN ZEXPORT int gzread OF((gzFile file, voidp buf, unsigned len));
820 Reads the given number of uncompressed bytes from the compressed file.
821 If the input file was not in gzip format, gzread copies the given number
822 @@ -1111,7 +1111,7 @@
823 gzread returns the number of uncompressed bytes actually read (0 for
824 end of file, -1 for error). */
826 -ZEXTERN int ZEXPORT gzwrite OF((gzFile file,
827 +ZEXTERN ZEXPORT int gzwrite OF((gzFile file,
828 voidpc buf, unsigned len));
830 Writes the given number of uncompressed bytes into the compressed file.
831 @@ -1119,7 +1119,7 @@
832 (0 in case of error).
835 -ZEXTERN int ZEXPORTVA gzprintf OF((gzFile file, const char *format, ...));
836 +ZEXTERN ZEXPORTVA int gzprintf OF((gzFile file, const char *format, ...));
838 Converts, formats, and writes the args to the compressed file under
839 control of the format string, as in fprintf. gzprintf returns the number of
840 @@ -1132,14 +1132,14 @@
841 because the secure snprintf() or vsnprintf() functions were not available.
844 -ZEXTERN int ZEXPORT gzputs OF((gzFile file, const char *s));
845 +ZEXTERN ZEXPORT int gzputs OF((gzFile file, const char *s));
847 Writes the given null-terminated string to the compressed file, excluding
848 the terminating null character.
849 gzputs returns the number of characters written, or -1 in case of error.
852 -ZEXTERN char * ZEXPORT gzgets OF((gzFile file, char *buf, int len));
853 +ZEXTERN ZEXPORT char * gzgets OF((gzFile file, char *buf, int len));
855 Reads bytes from the compressed file until len-1 characters are read, or
856 a newline character is read and transferred to buf, or an end-of-file
857 @@ -1148,19 +1148,19 @@
858 gzgets returns buf, or Z_NULL in case of error.
861 -ZEXTERN int ZEXPORT gzputc OF((gzFile file, int c));
862 +ZEXTERN ZEXPORT int gzputc OF((gzFile file, int c));
864 Writes c, converted to an unsigned char, into the compressed file.
865 gzputc returns the value that was written, or -1 in case of error.
868 -ZEXTERN int ZEXPORT gzgetc OF((gzFile file));
869 +ZEXTERN ZEXPORT int gzgetc OF((gzFile file));
871 Reads one byte from the compressed file. gzgetc returns this byte
872 or -1 in case of end of file or error.
875 -ZEXTERN int ZEXPORT gzungetc OF((int c, gzFile file));
876 +ZEXTERN ZEXPORT int gzungetc OF((int c, gzFile file));
878 Push one character back onto the stream to be read again later.
879 Only one character of push-back is allowed. gzungetc() returns the
880 @@ -1170,7 +1170,7 @@
884 -ZEXTERN int ZEXPORT gzflush OF((gzFile file, int flush));
885 +ZEXTERN ZEXPORT int gzflush OF((gzFile file, int flush));
887 Flushes all pending output into the compressed file. The parameter
888 flush is as in the deflate() function. The return value is the zlib
889 @@ -1180,7 +1180,7 @@
893 -ZEXTERN z_off_t ZEXPORT gzseek OF((gzFile file,
894 +ZEXTERN ZEXPORT z_off_t gzseek OF((gzFile file,
895 z_off_t offset, int whence));
897 Sets the starting position for the next gzread or gzwrite on the
898 @@ -1198,14 +1198,14 @@
899 would be before the current position.
902 -ZEXTERN int ZEXPORT gzrewind OF((gzFile file));
903 +ZEXTERN ZEXPORT int gzrewind OF((gzFile file));
905 Rewinds the given file. This function is supported only for reading.
907 gzrewind(file) is equivalent to (int)gzseek(file, 0L, SEEK_SET)
910 -ZEXTERN z_off_t ZEXPORT gztell OF((gzFile file));
911 +ZEXTERN ZEXPORT z_off_t gztell OF((gzFile file));
913 Returns the starting position for the next gzread or gzwrite on the
914 given compressed file. This position represents a number of bytes in the
915 @@ -1214,26 +1214,26 @@
916 gztell(file) is equivalent to gzseek(file, 0L, SEEK_CUR)
919 -ZEXTERN int ZEXPORT gzeof OF((gzFile file));
920 +ZEXTERN ZEXPORT int gzeof OF((gzFile file));
922 Returns 1 when EOF has previously been detected reading the given
923 input stream, otherwise zero.
926 -ZEXTERN int ZEXPORT gzdirect OF((gzFile file));
927 +ZEXTERN ZEXPORT int gzdirect OF((gzFile file));
929 Returns 1 if file is being read directly without decompression, otherwise
933 -ZEXTERN int ZEXPORT gzclose OF((gzFile file));
934 +ZEXTERN ZEXPORT int gzclose OF((gzFile file));
936 Flushes all pending output if necessary, closes the compressed file
937 and deallocates all the (de)compression state. The return value is the zlib
938 error number (see function gzerror below).
941 -ZEXTERN const char * ZEXPORT gzerror OF((gzFile file, int *errnum));
942 +ZEXTERN ZEXPORT const char * gzerror OF((gzFile file, int *errnum));
944 Returns the error message for the last error which occurred on the
945 given compressed file. errnum is set to zlib error number. If an
946 @@ -1242,7 +1242,7 @@
947 to get the exact error code.
950 -ZEXTERN void ZEXPORT gzclearerr OF((gzFile file));
951 +ZEXTERN ZEXPORT void gzclearerr OF((gzFile file));
953 Clears the error and end-of-file flags for file. This is analogous to the
954 clearerr() function in stdio. This is useful for continuing to read a gzip
955 @@ -1257,7 +1257,7 @@
959 -ZEXTERN uLong ZEXPORT adler32 OF((uLong adler, const Bytef *buf, uInt len));
960 +ZEXTERN ZEXPORT uLong adler32 OF((uLong adler, const Bytef *buf, uInt len));
962 Update a running Adler-32 checksum with the bytes buf[0..len-1] and
963 return the updated checksum. If buf is NULL, this function returns
964 @@ -1282,7 +1282,7 @@
965 seq1 and seq2 concatenated, requiring only adler1, adler2, and len2.
968 -ZEXTERN uLong ZEXPORT crc32 OF((uLong crc, const Bytef *buf, uInt len));
969 +ZEXTERN ZEXPORT uLong crc32 OF((uLong crc, const Bytef *buf, uInt len));
971 Update a running CRC-32 with the bytes buf[0..len-1] and return the
972 updated CRC-32. If buf is NULL, this function returns the required initial
973 @@ -1314,17 +1314,17 @@
974 /* deflateInit and inflateInit are macros to allow checking the zlib version
975 * and the compiler's view of z_stream:
977 -ZEXTERN int ZEXPORT deflateInit_ OF((z_streamp strm, int level,
978 +ZEXTERN ZEXPORT int deflateInit_ OF((z_streamp strm, int level,
979 const char *version, int stream_size));
980 -ZEXTERN int ZEXPORT inflateInit_ OF((z_streamp strm,
981 +ZEXTERN ZEXPORT int inflateInit_ OF((z_streamp strm,
982 const char *version, int stream_size));
983 -ZEXTERN int ZEXPORT deflateInit2_ OF((z_streamp strm, int level, int method,
984 +ZEXTERN ZEXPORT int deflateInit2_ OF((z_streamp strm, int level, int method,
985 int windowBits, int memLevel,
986 int strategy, const char *version,
988 -ZEXTERN int ZEXPORT inflateInit2_ OF((z_streamp strm, int windowBits,
989 +ZEXTERN ZEXPORT int inflateInit2_ OF((z_streamp strm, int windowBits,
990 const char *version, int stream_size));
991 -ZEXTERN int ZEXPORT inflateBackInit_ OF((z_streamp strm, int windowBits,
992 +ZEXTERN ZEXPORT int inflateBackInit_ OF((z_streamp strm, int windowBits,
993 unsigned char FAR *window,
996 @@ -1346,9 +1346,9 @@
997 struct internal_state {int dummy;}; /* hack for buggy compilers */
1000 -ZEXTERN const char * ZEXPORT zError OF((int));
1001 -ZEXTERN int ZEXPORT inflateSyncPoint OF((z_streamp z));
1002 -ZEXTERN const uLongf * ZEXPORT get_crc_table OF((void));
1003 +ZEXTERN ZEXPORT const char * zError OF((int));
1004 +ZEXTERN ZEXPORT int inflateSyncPoint OF((z_streamp z));
1005 +ZEXTERN ZEXPORT const uLongf * get_crc_table OF((void));
1009 --- zlib-1.2.3-orig/zutil.c~visibility
1010 +++ zlib-1.2.3-orig/zutil.c
1015 -const char * ZEXPORT zlibVersion()
1016 +ZEXPORT const char * zlibVersion()
1018 return ZLIB_VERSION;
1021 -uLong ZEXPORT zlibCompileFlags()
1022 +ZEXPORT uLong zlibCompileFlags()
1027 /* exported to allow conversion of error code to string for compress() and
1030 -const char * ZEXPORT zError(err)
1031 +ZEXPORT const char * zError(err)
1034 return ERR_MSG(err);