From: gameblabla Date: Thu, 7 Mar 2019 20:05:25 +0000 (+0100) Subject: Fix for compiling it against newer zlib versions. X-Git-Tag: r23~160^2 X-Git-Url: https://notaz.gp2x.de/cgi-bin/gitweb.cgi?a=commitdiff_plain;h=2dd6a826efdfffd4e3f4659d392c8b1c386b2915;p=pcsx_rearmed.git Fix for compiling it against newer zlib versions. --- diff --git a/libpcsxcore/cdriso.c b/libpcsxcore/cdriso.c index 515370f7..dca64fad 100644 --- a/libpcsxcore/cdriso.c +++ b/libpcsxcore/cdriso.c @@ -1089,7 +1089,7 @@ static int cdread_sub_mixed(FILE *f, unsigned int base, void *dest, int sector) return ret; } -static int uncompress2(void *out, unsigned long *out_size, void *in, unsigned long in_size) +static int uncompress2_pcsx(void *out, unsigned long *out_size, void *in, unsigned long in_size) { static z_stream z; int ret = 0; @@ -1169,7 +1169,7 @@ static int cdread_compressed(FILE *f, unsigned int base, void *dest, int sector) if (is_compressed) { cdbuffer_size_expect = sizeof(compr_img->buff_raw[0]) << compr_img->block_shift; cdbuffer_size = cdbuffer_size_expect; - ret = uncompress2(compr_img->buff_raw[0], &cdbuffer_size, compr_img->buff_compressed, size); + ret = uncompress2_pcsx(compr_img->buff_raw[0], &cdbuffer_size, compr_img->buff_compressed, size); if (ret != 0) { SysPrintf("uncompress failed with %d for block %d, sector %d\n", ret, block, sector); diff --git a/plugins/cdrcimg/cdrcimg.c b/plugins/cdrcimg/cdrcimg.c index 76cdfbaa..91cf1cad 100644 --- a/plugins/cdrcimg/cdrcimg.c +++ b/plugins/cdrcimg/cdrcimg.c @@ -98,7 +98,7 @@ static long CDRgetTD(unsigned char track, unsigned char *buffer) return 0; } -int uncompress2(void *out, unsigned long *out_size, void *in, unsigned long in_size) +static int uncompress2_pcsx(void *out, unsigned long *out_size, void *in, unsigned long in_size) { static z_stream z; int ret = 0; @@ -199,7 +199,7 @@ static long CDRreadTrack(unsigned char *time) ret = uncompress(cdbuffer->raw[0], &cdbuffer_size, cdbuffer->compressed, size); break; case CDRC_ZLIB2: - ret = uncompress2(cdbuffer->raw[0], &cdbuffer_size, cdbuffer->compressed, size); + ret = uncompress2_pcsx(cdbuffer->raw[0], &cdbuffer_size, cdbuffer->compressed, size); break; case CDRC_BZ: ret = pBZ2_bzBuffToBuffDecompress((char *)cdbuffer->raw, (unsigned int *)&cdbuffer_size,