(libretro-common) Cleanup/style nits for archive_file_{7z/zlib}
This commit is contained in:
parent
e639f12e35
commit
89820220b7
|
@ -58,8 +58,6 @@ static void* sevenzip_stream_new(void)
|
||||||
struct sevenzip_context_t *sevenzip_context =
|
struct sevenzip_context_t *sevenzip_context =
|
||||||
(struct sevenzip_context_t*)calloc(1, sizeof(struct sevenzip_context_t));
|
(struct sevenzip_context_t*)calloc(1, sizeof(struct sevenzip_context_t));
|
||||||
|
|
||||||
memset(sevenzip_context, 0, sizeof(struct sevenzip_context_t));
|
|
||||||
|
|
||||||
/* These are the allocation routines - currently using
|
/* These are the allocation routines - currently using
|
||||||
* the non-standard 7zip choices. */
|
* the non-standard 7zip choices. */
|
||||||
sevenzip_context->allocImp.Alloc = SzAlloc;
|
sevenzip_context->allocImp.Alloc = SzAlloc;
|
||||||
|
|
|
@ -57,7 +57,9 @@ static bool zlib_stream_decompress_data_to_file_init(
|
||||||
if (!handle)
|
if (!handle)
|
||||||
return false;
|
return false;
|
||||||
|
|
||||||
if (!(handle->stream = zlib_inflate_backend.stream_new()))
|
handle->stream = zlib_inflate_backend.stream_new();
|
||||||
|
|
||||||
|
if (!handle->stream)
|
||||||
goto error;
|
goto error;
|
||||||
|
|
||||||
if (zlib_inflate_backend.define)
|
if (zlib_inflate_backend.define)
|
||||||
|
@ -123,10 +125,12 @@ static bool zip_file_decompressed_handle(
|
||||||
handle, cdata, csize, size))
|
handle, cdata, csize, size))
|
||||||
return false;
|
return false;
|
||||||
|
|
||||||
do{
|
do
|
||||||
|
{
|
||||||
ret = handle->backend->stream_decompress_data_to_file_iterate(
|
ret = handle->backend->stream_decompress_data_to_file_iterate(
|
||||||
handle->stream);
|
handle->stream);
|
||||||
}while(ret == 0);
|
}while(ret == 0);
|
||||||
|
|
||||||
#if 0
|
#if 0
|
||||||
handle->real_checksum = handle->backend->stream_crc_calculate(0,
|
handle->real_checksum = handle->backend->stream_crc_calculate(0,
|
||||||
handle->data, size);
|
handle->data, size);
|
||||||
|
@ -231,9 +235,9 @@ static int zip_file_read(
|
||||||
const char *optional_outfile)
|
const char *optional_outfile)
|
||||||
{
|
{
|
||||||
file_archive_transfer_t zlib;
|
file_archive_transfer_t zlib;
|
||||||
|
struct archive_extract_userdata userdata = {{0}};
|
||||||
bool returnerr = true;
|
bool returnerr = true;
|
||||||
int ret = 0;
|
int ret = 0;
|
||||||
struct archive_extract_userdata userdata = {{0}};
|
|
||||||
|
|
||||||
zlib.type = ARCHIVE_TRANSFER_INIT;
|
zlib.type = ARCHIVE_TRANSFER_INIT;
|
||||||
|
|
||||||
|
|
Loading…
Reference in New Issue