1 /* Copyright 2007-2012 Fredrik Wikstrom. All rights reserved.
3 ** Redistribution and use in source and binary forms, with or without
4 ** modification, are permitted provided that the following conditions
7 ** 1. Redistributions of source code must retain the above copyright
8 ** notice, this list of conditions and the following disclaimer.
10 ** 2. Redistributions in binary form must reproduce the above copyright
11 ** notice, this list of conditions and the following disclaimer in the
12 ** documentation and/or other materials provided with the distribution.
14 ** THIS SOFTWARE IS PROVIDED BY THE COPYRIGHT HOLDERS AND CONTRIBUTORS `AS IS'
15 ** AND ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE
16 ** IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE
17 ** ARE DISCLAIMED. IN NO EVENT SHALL THE COPYRIGHT OWNER OR CONTRIBUTORS BE
18 ** LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR
19 ** CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF
20 ** SUBSTITUTE GOODS OR SERVICES; LOSS OF USE, DATA, OR PROFITS; OR BUSINESS
21 ** INTERRUPTION) HOWEVER CAUSED AND ON ANY THEORY OF LIABILITY, WHETHER IN
22 ** CONTRACT, STRICT LIABILITY, OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE)
23 ** ARISING IN ANY WAY OUT OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE
24 ** POSSIBILITY OF SUCH DAMAGE.
27 #include <exec/exec.h>
29 #include <proto/exec.h>
32 #include <SDI_compiler.h>
33 #include "z.library_rev.h"
35 #define LIBNAME "z.library"
36 const char USED_VAR verstag
[] = VERSTAG
;
42 struct ExecBase
*SysBase
;
45 struct Library libNode
;
50 int malloc_init(void);
51 void malloc_exit(void);
54 static AROS_UFP3(struct ZBase
*, LibInit
,
55 AROS_UFPA(struct ZBase
*, libBase
, D0
),
56 AROS_UFPA(BPTR
, seglist
, A0
),
57 AROS_UFPA(struct ExecBase
*, exec_base
, A6
)
59 static AROS_LD1(struct ZBase
*, LibOpen
,
60 AROS_LPA(ULONG
, version
, D0
),
61 struct ZBase
*, libBase
, 1, Zlib
63 static AROS_LD0(BPTR
, LibClose
,
64 struct ZBase
*, libBase
, 2, Zlib
66 static AROS_LD0(BPTR
, LibExpunge
,
67 struct ZBase
*, libBase
, 3, Zlib
69 static AROS_LD0(APTR
, LibReserved
,
70 struct ZBase
*, libBase
, 4, Zlib
72 static AROS_LD0(const char *, ZlibVersion
,
73 struct ZBase
*, libBase
, 5, Zlib
75 static AROS_LD2(LONG
, DeflateInit
,
76 AROS_LPA(z_streamp
, strm
, A0
),
77 AROS_LPA(LONG
, level
, D0
),
78 struct ZBase
*, libBase
, 6, Zlib
80 static AROS_LD2(LONG
, Deflate
,
81 AROS_LPA(z_streamp
, strm
, A0
),
82 AROS_LPA(LONG
, flush
, D0
),
83 struct ZBase
*, libBase
, 7, Zlib
85 static AROS_LD1(LONG
, DeflateEnd
,
86 AROS_LPA(z_streamp
, strm
, A0
),
87 struct ZBase
*, libBase
, 8, Zlib
89 static AROS_LD1(LONG
, InflateInit
,
90 AROS_LPA(z_streamp
, strm
, A0
),
91 struct ZBase
*, libBase
, 9, Zlib
93 static AROS_LD2(LONG
, Inflate
,
94 AROS_LPA(z_streamp
, strm
, A0
),
95 AROS_LPA(LONG
, flush
, D0
),
96 struct ZBase
*, libBase
, 10, Zlib
98 static AROS_LD1(LONG
, InflateEnd
,
99 AROS_LPA(z_streamp
, strm
, A0
),
100 struct ZBase
*, libBase
, 11, Zlib
102 static AROS_LD6(LONG
, DeflateInit2
,
103 AROS_LPA(z_streamp
, strm
, A0
),
104 AROS_LPA(LONG
, level
, D0
),
105 AROS_LPA(LONG
, method
, D1
),
106 AROS_LPA(LONG
, windowBits
, D2
),
107 AROS_LPA(LONG
, memLevel
, D3
),
108 AROS_LPA(LONG
, strategy
, D4
),
109 struct ZBase
*, libBase
, 12, Zlib
111 static AROS_LD3(LONG
, DeflateSetDictionary
,
112 AROS_LPA(z_streamp
, strm
, A0
),
113 AROS_LPA(APTR
, dictionary
, A1
),
114 AROS_LPA(ULONG
, dictLength
, D0
),
115 struct ZBase
*, libBase
, 13, Zlib
117 static AROS_LD2(LONG
, DeflateCopy
,
118 AROS_LPA(z_streamp
, dest
, A0
),
119 AROS_LPA(z_streamp
, source
, A1
),
120 struct ZBase
*, libBase
, 14, Zlib
122 static AROS_LD1(LONG
, DeflateReset
,
123 AROS_LPA(z_streamp
, strm
, A0
),
124 struct ZBase
*, libBase
, 15, Zlib
126 static AROS_LD3(LONG
, DeflateParams
,
127 AROS_LPA(z_streamp
, strm
, A0
),
128 AROS_LPA(LONG
, level
, D0
),
129 AROS_LPA(LONG
, strategy
, D1
),
130 struct ZBase
*, libBase
, 16, Zlib
132 static AROS_LD2(LONG
, InflateInit2
,
133 AROS_LPA(z_streamp
, strm
, A0
),
134 AROS_LPA(LONG
, windowBits
, D0
),
135 struct ZBase
*, libBase
, 17, Zlib
137 static AROS_LD3(LONG
, InflateSetDictionary
,
138 AROS_LPA(z_streamp
, strm
, A0
),
139 AROS_LPA(APTR
, dictionary
, A1
),
140 AROS_LPA(ULONG
, dictLength
, D0
),
141 struct ZBase
*, libBase
, 18, Zlib
143 static AROS_LD1(LONG
, InflateReset
,
144 AROS_LPA(z_streamp
, strm
, A0
),
145 struct ZBase
*, libBase
, 19, Zlib
147 static AROS_LD4(LONG
, Compress
,
148 AROS_LPA(APTR
, dest
, A0
),
149 AROS_LPA(ULONG
*, destLen
, A1
),
150 AROS_LPA(APTR
, source
, A2
),
151 AROS_LPA(ULONG
, sourceLen
, D0
),
152 struct ZBase
*, libBase
, 20, Zlib
154 static AROS_LD4(LONG
, Uncompress
,
155 AROS_LPA(APTR
, dest
, A0
),
156 AROS_LPA(ULONG
*, destLen
, A1
),
157 AROS_LPA(APTR
, source
, A2
),
158 AROS_LPA(ULONG
, sourceLen
, D0
),
159 struct ZBase
*, libBase
, 21, Zlib
161 static AROS_LD3(ULONG
, Adler32
,
162 AROS_LPA(ULONG
, adler
, D0
),
163 AROS_LPA(APTR
, buf
, A0
),
164 AROS_LPA(ULONG
, len
, D1
),
165 struct ZBase
*, libBase
, 22, Zlib
167 static AROS_LD3(ULONG
, CRC32
,
168 AROS_LPA(ULONG
, crc
, D0
),
169 AROS_LPA(APTR
, buf
, A0
),
170 AROS_LPA(ULONG
, len
, D1
),
171 struct ZBase
*, libBase
, 23, Zlib
173 static AROS_LD1(LONG
, InflateSync
,
174 AROS_LPA(z_streamp
, strm
, A0
),
175 struct ZBase
*, libBase
, 24, Zlib
178 static struct ZBase
*LibInit (REG(d0
, struct ZBase
*libBase
), REG(a0
, BPTR seglist
),
179 REG(a6
, struct ExecBase
*exec_base
));
180 static struct ZBase
*Zlib_LibOpen (REG(a6
, struct ZBase
*libBase
), REG(d0
, ULONG version
));
181 static BPTR
Zlib_LibClose (REG(a6
, struct ZBase
*libBase
));
182 static BPTR
Zlib_LibExpunge (REG(a6
, struct ZBase
*libBase
));
183 static APTR
Zlib_LibReserved (REG(a6
, struct ZBase
*libBase
));
184 static const char *Zlib_ZlibVersion(void);
185 static LONG
Zlib_DeflateInit(REG(a0
, z_streamp strm
), REG(d0
, LONG level
));
186 static LONG
Zlib_Deflate(REG(a0
, z_streamp strm
), REG(d0
, LONG flush
));
187 static LONG
Zlib_DeflateEnd(REG(a0
, z_streamp strm
));
188 static LONG
Zlib_InflateInit(REG(a0
, z_streamp strm
));
189 static LONG
Zlib_Inflate(REG(a0
, z_streamp strm
), REG(d0
, LONG flush
));
190 static LONG
Zlib_InflateEnd(REG(a0
, z_streamp strm
));
191 static LONG
Zlib_DeflateInit2(REG(a0
, z_streamp strm
), REG(d0
, LONG level
), REG(d1
, LONG method
),
192 REG(d2
, LONG windowBits
), REG(d3
, LONG memLevel
), REG(d4
, LONG strategy
));
193 static LONG
Zlib_DeflateSetDictionary(REG(a0
, z_streamp strm
), REG(a1
, APTR dictionary
),
194 REG(d0
, ULONG dictLength
));
195 static LONG
Zlib_DeflateCopy(REG(a0
, z_streamp dest
), REG(a1
, z_streamp source
));
196 static LONG
Zlib_DeflateReset(REG(a0
, z_streamp strm
));
197 static LONG
Zlib_DeflateParams(REG(a0
, z_streamp strm
), REG(d0
, LONG level
), REG(d1
, LONG strategy
));
198 static LONG
Zlib_InflateInit2(REG(a0
, z_streamp strm
), REG(d0
, LONG windowBits
));
199 static LONG
Zlib_InflateSetDictionary(REG(a0
, z_streamp strm
), REG(a1
, APTR dictionary
),
200 REG(d0
, ULONG dictLength
));
201 static LONG
Zlib_InflateReset(REG(a0
, z_streamp strm
));
202 static LONG
Zlib_Compress(REG(a0
, APTR dest
), REG(a1
, ULONG
*destLen
), REG(a2
, APTR source
),
203 REG(d0
, ULONG sourceLen
));
204 static LONG
Zlib_Uncompress(REG(a0
, APTR dest
), REG(a1
, ULONG
*destLen
), REG(a2
, APTR source
),
205 REG(d0
, ULONG sourceLen
));
206 static ULONG
Zlib_Adler32(REG(d0
, ULONG adler
), REG(a0
, APTR buf
), REG(d1
, ULONG len
));
207 static ULONG
Zlib_CRC32(REG(d0
, ULONG crc
), REG(a0
, APTR buf
), REG(d1
, ULONG len
));
208 static LONG
Zlib_InflateSync(REG(a0
, z_streamp strm
));
213 #define LIB_ENTRY(a,b) AROS_SLIB_ENTRY(a, Zlib, b)
215 #define LIB_ENTRY(a,b) AROS_SLIB_ENTRY(a, Zlib)
218 #define LIB_ENTRY(a,b) Zlib_##a
221 CONST_APTR LibVectors
[] = {
222 (APTR
)LIB_ENTRY(LibOpen
, 1),
223 (APTR
)LIB_ENTRY(LibClose
, 2),
224 (APTR
)LIB_ENTRY(LibExpunge
, 3),
225 (APTR
)LIB_ENTRY(LibReserved
, 4),
226 (APTR
)LIB_ENTRY(ZlibVersion
, 5),
227 (APTR
)LIB_ENTRY(DeflateInit
, 6),
228 (APTR
)LIB_ENTRY(Deflate
, 7),
229 (APTR
)LIB_ENTRY(DeflateEnd
, 8),
230 (APTR
)LIB_ENTRY(InflateInit
, 9),
231 (APTR
)LIB_ENTRY(Inflate
, 10),
232 (APTR
)LIB_ENTRY(InflateEnd
, 11),
233 (APTR
)LIB_ENTRY(DeflateInit2
, 12),
234 (APTR
)LIB_ENTRY(DeflateSetDictionary
, 13),
235 (APTR
)LIB_ENTRY(DeflateCopy
, 14),
236 (APTR
)LIB_ENTRY(DeflateReset
, 15),
237 (APTR
)LIB_ENTRY(DeflateParams
, 16),
238 (APTR
)LIB_ENTRY(InflateInit2
, 17),
239 (APTR
)LIB_ENTRY(InflateSetDictionary
, 18),
240 (APTR
)LIB_ENTRY(InflateReset
, 19),
241 (APTR
)LIB_ENTRY(Compress
, 20),
242 (APTR
)LIB_ENTRY(Uncompress
, 21),
243 (APTR
)LIB_ENTRY(Adler32
, 22),
244 (APTR
)LIB_ENTRY(CRC32
, 23),
245 (APTR
)LIB_ENTRY(InflateSync
, 24),
249 const IPTR LibInitTab
[] = {
250 sizeof(struct ZBase
),
256 const struct Resident USED_VAR ROMTag
= {
258 (struct Resident
*)&ROMTag
,
270 static AROS_UFH3(struct ZBase
*, LibInit
,
271 AROS_UFHA(struct ZBase
*, libBase
, D0
),
272 AROS_UFHA(BPTR
, seglist
, A0
),
273 AROS_UFHA(struct ExecBase
*, exec_base
, A6
)
278 static struct ZBase
*LibInit (REG(d0
, struct ZBase
*libBase
), REG(a0
, BPTR seglist
),
279 REG(a6
, struct ExecBase
*exec_base
))
282 libBase
->libNode
.lib_Node
.ln_Type
= NT_LIBRARY
;
283 libBase
->libNode
.lib_Node
.ln_Pri
= 0;
284 libBase
->libNode
.lib_Node
.ln_Name
= LIBNAME
;
285 libBase
->libNode
.lib_Flags
= LIBF_SUMUSED
|LIBF_CHANGED
;
286 libBase
->libNode
.lib_Version
= VERSION
;
287 libBase
->libNode
.lib_Revision
= REVISION
;
288 libBase
->libNode
.lib_IdString
= VSTRING
;
290 libBase
->seglist
= seglist
;
298 DeleteLibrary((struct Library
*)libBase
);
307 static AROS_LH1(struct ZBase
*, LibOpen
,
308 AROS_LHA(ULONG
, version
, D0
),
309 struct ZBase
*, libBase
, 1, Zlib
314 static struct ZBase
*Zlib_LibOpen (REG(a6
, struct ZBase
*libBase
), REG(d0
, ULONG version
)) {
316 libBase
->libNode
.lib_OpenCnt
++;
317 libBase
->libNode
.lib_Flags
&= ~LIBF_DELEXP
;
325 static AROS_LH0(BPTR
, LibClose
,
326 struct ZBase
*, libBase
, 2, Zlib
331 static BPTR
Zlib_LibClose (REG(a6
, struct ZBase
*libBase
)) {
333 libBase
->libNode
.lib_OpenCnt
--;
341 static AROS_LH0(BPTR
, LibExpunge
,
342 struct ZBase
*, libBase
, 3, Zlib
347 static BPTR
Zlib_LibExpunge (REG(a6
, struct ZBase
*libBase
)) {
351 if (libBase
->libNode
.lib_OpenCnt
> 0) {
352 libBase
->libNode
.lib_Flags
|= LIBF_DELEXP
;
356 Remove(&libBase
->libNode
.lib_Node
);
358 result
= libBase
->seglist
;
362 DeleteLibrary((struct Library
*)libBase
);
371 static AROS_LH0(APTR
, LibReserved
,
372 struct ZBase
*, libBase
, 4, Zlib
380 static APTR
Zlib_LibReserved (REG(a6
, struct ZBase
*libBase
)) {
386 static AROS_LH0(const char *, ZlibVersion
,
387 struct ZBase
*, libBase
, 5, Zlib
392 static const char *Zlib_ZlibVersion(void) {
394 return zlibVersion();
401 static AROS_LH2(LONG
, DeflateInit
,
402 AROS_LHA(z_streamp
, strm
, A0
),
403 AROS_LHA(LONG
, level
, D0
),
404 struct ZBase
*, libBase
, 6, Zlib
409 static LONG
Zlib_DeflateInit(REG(a0
, z_streamp strm
), REG(d0
, LONG level
)) {
411 return deflateInit(strm
, level
);
418 static AROS_LH2(LONG
, Deflate
,
419 AROS_LHA(z_streamp
, strm
, A0
),
420 AROS_LHA(LONG
, flush
, D0
),
421 struct ZBase
*, libBase
, 7, Zlib
426 static LONG
Zlib_Deflate(REG(a0
, z_streamp strm
), REG(d0
, LONG flush
)) {
428 return deflate(strm
, flush
);
435 static AROS_LH1(LONG
, DeflateEnd
,
436 AROS_LHA(z_streamp
, strm
, A0
),
437 struct ZBase
*, libBase
, 8, Zlib
442 static LONG
Zlib_DeflateEnd(REG(a0
, z_streamp strm
)) {
444 return deflateEnd(strm
);
451 static AROS_LH1(LONG
, InflateInit
,
452 AROS_LHA(z_streamp
, strm
, A0
),
453 struct ZBase
*, libBase
, 9, Zlib
458 static LONG
Zlib_InflateInit(REG(a0
, z_streamp strm
)) {
460 return inflateInit(strm
);
467 static AROS_LH2(LONG
, Inflate
,
468 AROS_LHA(z_streamp
, strm
, A0
),
469 AROS_LHA(LONG
, flush
, D0
),
470 struct ZBase
*, libBase
, 10, Zlib
475 static LONG
Zlib_Inflate(REG(a0
, z_streamp strm
), REG(d0
, LONG flush
)) {
477 return inflate(strm
, flush
);
484 static AROS_LH1(LONG
, InflateEnd
,
485 AROS_LHA(z_streamp
, strm
, A0
),
486 struct ZBase
*, libBase
, 11, Zlib
491 static LONG
Zlib_InflateEnd(REG(a0
, z_streamp strm
)) {
493 return inflateEnd(strm
);
500 static AROS_LH6(LONG
, DeflateInit2
,
501 AROS_LHA(z_streamp
, strm
, A0
),
502 AROS_LHA(LONG
, level
, D0
),
503 AROS_LHA(LONG
, method
, D1
),
504 AROS_LHA(LONG
, windowBits
, D2
),
505 AROS_LHA(LONG
, memLevel
, D3
),
506 AROS_LHA(LONG
, strategy
, D4
),
507 struct ZBase
*, libBase
, 12, Zlib
512 static LONG
Zlib_DeflateInit2(REG(a0
, z_streamp strm
), REG(d0
, LONG level
), REG(d1
, LONG method
),
513 REG(d2
, LONG windowBits
), REG(d3
, LONG memLevel
), REG(d4
, LONG strategy
))
516 return deflateInit2(strm
, level
, method
, windowBits
, memLevel
, strategy
);
523 static AROS_LH3(LONG
, DeflateSetDictionary
,
524 AROS_LHA(z_streamp
, strm
, A0
),
525 AROS_LHA(APTR
, dictionary
, A1
),
526 AROS_LHA(ULONG
, dictLength
, D0
),
527 struct ZBase
*, libBase
, 13, Zlib
532 static LONG
Zlib_DeflateSetDictionary(REG(a0
, z_streamp strm
), REG(a1
, APTR dictionary
),
533 REG(d0
, ULONG dictLength
))
536 return deflateSetDictionary(strm
, dictionary
, dictLength
);
543 static AROS_LH2(LONG
, DeflateCopy
,
544 AROS_LHA(z_streamp
, dest
, A0
),
545 AROS_LHA(z_streamp
, source
, A1
),
546 struct ZBase
*, libBase
, 14, Zlib
551 static LONG
Zlib_DeflateCopy(REG(a0
, z_streamp dest
), REG(a1
, z_streamp source
)) {
553 return deflateCopy(dest
, source
);
560 static AROS_LH1(LONG
, DeflateReset
,
561 AROS_LHA(z_streamp
, strm
, A0
),
562 struct ZBase
*, libBase
, 15, Zlib
567 static LONG
Zlib_DeflateReset(REG(a0
, z_streamp strm
)) {
569 return deflateReset(strm
);
576 static AROS_LH3(LONG
, DeflateParams
,
577 AROS_LHA(z_streamp
, strm
, A0
),
578 AROS_LHA(LONG
, level
, D0
),
579 AROS_LHA(LONG
, strategy
, D1
),
580 struct ZBase
*, libBase
, 16, Zlib
585 static LONG
Zlib_DeflateParams(REG(a0
, z_streamp strm
), REG(d0
, LONG level
), REG(d1
, LONG strategy
)) {
587 return deflateParams(strm
, level
, strategy
);
594 static AROS_LH2(LONG
, InflateInit2
,
595 AROS_LHA(z_streamp
, strm
, A0
),
596 AROS_LHA(LONG
, windowBits
, D0
),
597 struct ZBase
*, libBase
, 17, Zlib
602 static LONG
Zlib_InflateInit2(REG(a0
, z_streamp strm
), REG(d0
, LONG windowBits
)) {
604 return inflateInit2(strm
, windowBits
);
611 static AROS_LH3(LONG
, InflateSetDictionary
,
612 AROS_LHA(z_streamp
, strm
, A0
),
613 AROS_LHA(APTR
, dictionary
, A1
),
614 AROS_LHA(ULONG
, dictLength
, D0
),
615 struct ZBase
*, libBase
, 18, Zlib
620 static LONG
Zlib_InflateSetDictionary(REG(a0
, z_streamp strm
), REG(a1
, APTR dictionary
),
621 REG(d0
, ULONG dictLength
))
624 return inflateSetDictionary(strm
, dictionary
, dictLength
);
631 static AROS_LH1(LONG
, InflateReset
,
632 AROS_LHA(z_streamp
, strm
, A0
),
633 struct ZBase
*, libBase
, 19, Zlib
638 static LONG
Zlib_InflateReset(REG(a0
, z_streamp strm
)) {
640 return inflateReset(strm
);
647 static AROS_LH4(LONG
, Compress
,
648 AROS_LHA(APTR
, dest
, A0
),
649 AROS_LHA(ULONG
*, destLen
, A1
),
650 AROS_LHA(APTR
, source
, A2
),
651 AROS_LHA(ULONG
, sourceLen
, D0
),
652 struct ZBase
*, libBase
, 20, Zlib
657 static LONG
Zlib_Compress(REG(a0
, APTR dest
), REG(a1
, ULONG
*destLen
), REG(a2
, APTR source
),
658 REG(d0
, ULONG sourceLen
))
661 return compress(dest
, destLen
, source
, sourceLen
);
668 static AROS_LH4(LONG
, Uncompress
,
669 AROS_LHA(APTR
, dest
, A0
),
670 AROS_LHA(ULONG
*, destLen
, A1
),
671 AROS_LHA(APTR
, source
, A2
),
672 AROS_LHA(ULONG
, sourceLen
, D0
),
673 struct ZBase
*, libBase
, 21, Zlib
678 static LONG
Zlib_Uncompress(REG(a0
, APTR dest
), REG(a1
, ULONG
*destLen
), REG(a2
, APTR source
),
679 REG(d0
, ULONG sourceLen
))
682 return uncompress(dest
, destLen
, source
, sourceLen
);
689 static AROS_LH3(ULONG
, Adler32
,
690 AROS_LHA(ULONG
, adler
, D0
),
691 AROS_LHA(APTR
, buf
, A0
),
692 AROS_LHA(ULONG
, len
, D1
),
693 struct ZBase
*, libBase
, 22, Zlib
698 static ULONG
Zlib_Adler32(REG(d0
, ULONG adler
), REG(a0
, APTR buf
), REG(d1
, ULONG len
)) {
700 return adler32(adler
, buf
, len
);
707 static AROS_LH3(ULONG
, CRC32
,
708 AROS_LHA(ULONG
, crc
, D0
),
709 AROS_LHA(APTR
, buf
, A0
),
710 AROS_LHA(ULONG
, len
, D1
),
711 struct ZBase
*, libBase
, 23, Zlib
716 static ULONG
Zlib_CRC32(REG(d0
, ULONG crc
), REG(a0
, APTR buf
), REG(d1
, ULONG len
)) {
718 return crc32(crc
, buf
, len
);
725 static AROS_LH1(LONG
, InflateSync
,
726 AROS_LHA(z_streamp
, strm
, A0
),
727 struct ZBase
*, libBase
, 24, Zlib
732 static LONG
Zlib_InflateSync(REG(a0
, z_streamp strm
)) {
734 return inflateSync(strm
);