Skip to content

Commit

Permalink
Added definition for zipOpenNewFileInZip64 for backwards compat #787
Browse files Browse the repository at this point in the history
  • Loading branch information
nmoinvaz committed Jun 15, 2024
1 parent b887f81 commit bfc8f6c
Show file tree
Hide file tree
Showing 2 changed files with 12 additions and 0 deletions.
8 changes: 8 additions & 0 deletions mz_compat.c
Original file line number Diff line number Diff line change
Expand Up @@ -575,6 +575,14 @@ int zipOpenNewFileInZip(zipFile file, const char *filename, const zip_fileinfo *
extrafield_global, size_extrafield_global, comment, compression_method, level, 0);
}

int zipOpenNewFileInZip64(zipFile file, const char *filename, const zip_fileinfo *zipfi,
const void *extrafield_local, uint16_t size_extrafield_local, const void *extrafield_global,
uint16_t size_extrafield_global, const char *comment, int compression_method, int level,
int zip64) {
return zipOpenNewFileInZip2_64(file, filename, zipfi, extrafield_local, size_extrafield_local,
extrafield_global, size_extrafield_global, comment, compression_method, level, 0, zip64);
}

int zipOpenNewFileInZip_64(zipFile file, const char *filename, const zip_fileinfo *zipfi,
const void *extrafield_local, uint16_t size_extrafield_local, const void *extrafield_global,
uint16_t size_extrafield_global, const char *comment, int compression_method, int level,
Expand Down
4 changes: 4 additions & 0 deletions mz_compat.h
Original file line number Diff line number Diff line change
Expand Up @@ -174,6 +174,10 @@ ZEXPORT void* zipGetStream_MZ(zipFile file);
ZEXPORT int zipOpenNewFileInZip(zipFile file, const char *filename, const zip_fileinfo *zipfi,
const void *extrafield_local, uint16_t size_extrafield_local, const void *extrafield_global,
uint16_t size_extrafield_global, const char *comment, int compression_method, int level);
ZEXPORT int zipOpenNewFileInZip64(zipFile file, const char *filename, const zip_fileinfo *zipfi,
const void *extrafield_local, uint16_t size_extrafield_local, const void *extrafield_global,
uint16_t size_extrafield_global, const char *comment, int compression_method, int level,
int zip64);
ZEXPORT int zipOpenNewFileInZip_64(zipFile file, const char *filename, const zip_fileinfo *zipfi,
const void *extrafield_local, uint16_t size_extrafield_local, const void *extrafield_global,
uint16_t size_extrafield_global, const char *comment, int compression_method, int level,
Expand Down

0 comments on commit bfc8f6c

Please sign in to comment.