forked from Imagelibrary/rtems
Stop using old-style function definitions.
This commit is contained in:
@@ -146,10 +146,10 @@ const char * ZEXPORT zError(
|
|||||||
|
|
||||||
#ifndef HAVE_MEMCPY
|
#ifndef HAVE_MEMCPY
|
||||||
|
|
||||||
void zmemcpy(dest, source, len)
|
void zmemcpy(
|
||||||
Bytef* dest;
|
Bytef* dest,
|
||||||
const Bytef* source;
|
const Bytef* source,
|
||||||
uInt len;
|
uInt len)
|
||||||
{
|
{
|
||||||
if (len == 0) return;
|
if (len == 0) return;
|
||||||
do {
|
do {
|
||||||
@@ -157,10 +157,10 @@ void zmemcpy(dest, source, len)
|
|||||||
} while (--len != 0);
|
} while (--len != 0);
|
||||||
}
|
}
|
||||||
|
|
||||||
int zmemcmp(s1, s2, len)
|
int zmemcmp(
|
||||||
const Bytef* s1;
|
const Bytef* s1,
|
||||||
const Bytef* s2;
|
const Bytef* s2,
|
||||||
uInt len;
|
uInt len)
|
||||||
{
|
{
|
||||||
uInt j;
|
uInt j;
|
||||||
|
|
||||||
@@ -170,9 +170,9 @@ int zmemcmp(s1, s2, len)
|
|||||||
return 0;
|
return 0;
|
||||||
}
|
}
|
||||||
|
|
||||||
void zmemzero(dest, len)
|
void zmemzero(
|
||||||
Bytef* dest;
|
Bytef* dest,
|
||||||
uInt len;
|
uInt len)
|
||||||
{
|
{
|
||||||
if (len == 0) return;
|
if (len == 0) return;
|
||||||
do {
|
do {
|
||||||
@@ -297,19 +297,19 @@ extern voidp calloc OF((uInt items, uInt size));
|
|||||||
extern void free OF((voidpf ptr));
|
extern void free OF((voidpf ptr));
|
||||||
#endif
|
#endif
|
||||||
|
|
||||||
voidpf zcalloc (opaque, items, size)
|
voidpf zcalloc (
|
||||||
voidpf opaque;
|
voidpf opaque,
|
||||||
unsigned items;
|
unsigned items,
|
||||||
unsigned size;
|
unsigned size)
|
||||||
{
|
{
|
||||||
if (opaque) items += size - size; /* make compiler happy */
|
if (opaque) items += size - size; /* make compiler happy */
|
||||||
return sizeof(uInt) > 2 ? (voidpf)malloc(items * size) :
|
return sizeof(uInt) > 2 ? (voidpf)malloc(items * size) :
|
||||||
(voidpf)calloc(items, size);
|
(voidpf)calloc(items, size);
|
||||||
}
|
}
|
||||||
|
|
||||||
void zcfree (opaque, ptr)
|
void zcfree (
|
||||||
voidpf opaque;
|
voidpf opaque,
|
||||||
voidpf ptr;
|
voidpf ptr)
|
||||||
{
|
{
|
||||||
free(ptr);
|
free(ptr);
|
||||||
if (opaque) return; /* make compiler happy */
|
if (opaque) return; /* make compiler happy */
|
||||||
|
|||||||
Reference in New Issue
Block a user