VirtualBox

Ignore:
Timestamp:
Jun 9, 2022 9:09:44 AM (3 years ago)
Author:
vboxsync
svn:sync-xref-src-repo-rev:
151769
Message:

libs/zlib: Upgrade to 1.2.12, bugref:8515

Location:
trunk/src/libs/zlib-1.2.12
Files:
2 edited

Legend:

Unmodified
Added
Removed
  • trunk/src/libs/zlib-1.2.12

    • Property svn:mergeinfo
      •  

        old new  
        2020/branches/dsen/gui3/src/libs/zlib-1.2.11:79645-79692
        2121/trunk/src/src/libs/zlib-1.2.11:92342
         22/vendor/zlib/1.2.12:151751
         23/vendor/zlib/current:150724-151750
  • trunk/src/libs/zlib-1.2.12/contrib/minizip/miniunz.c

    r76163 r95239  
    4646#include <errno.h>
    4747#include <fcntl.h>
     48#include <sys/stat.h>
    4849
    4950#ifdef _WIN32
     
    8182    dosdate : the new date at the MSDos format (4 bytes)
    8283    tmu_date : the SAME new date at the tm_unz format */
    83 void change_file_date(filename,dosdate,tmu_date)
     84static void change_file_date(filename,dosdate,tmu_date)
    8485    const char *filename;
    8586    uLong dosdate;
     
    9899  CloseHandle(hFile);
    99100#else
    100 #ifdef unix || __APPLE__
     101#if defined(unix) || defined(__APPLE__)
     102  (void)dosdate;
    101103  struct utimbuf ut;
    102104  struct tm newdate;
     
    122124   As I don't know well Unix, I wait feedback for the unix portion */
    123125
    124 int mymkdir(dirname)
     126static int mymkdir(dirname)
    125127    const char* dirname;
    126128{
     
    136138}
    137139
    138 int makedir (newdir)
    139     char *newdir;
     140static int makedir (newdir)
     141    const char *newdir;
    140142{
    141143  char *buffer ;
    142144  char *p;
    143   int  len = (int)strlen(newdir);
    144 
    145   if (len <= 0)
     145  size_t len = strlen(newdir);
     146
     147  if (len == 0)
    146148    return 0;
    147149
     
    186188}
    187189
    188 void do_banner()
     190static void do_banner()
    189191{
    190192    printf("MiniUnz 1.01b, demo of zLib + Unz package written by Gilles Vollant\n");
     
    192194}
    193195
    194 void do_help()
     196static void do_help()
    195197{
    196198    printf("Usage : miniunz [-e] [-x] [-v] [-l] [-o] [-p password] file.zip [file_to_extr.] [-d extractdir]\n\n" \
     
    204206}
    205207
    206 void Display64BitsSize(ZPOS64_T n, int size_char)
     208static void Display64BitsSize(ZPOS64_T n, int size_char)
    207209{
    208210  /* to avoid compatibility problem , we do here the conversion */
     
    232234}
    233235
    234 int do_list(uf)
     236static int do_list(uf)
    235237    unzFile uf;
    236238{
     
    310312
    311313
    312 int do_extract_currentfile(uf,popt_extract_without_path,popt_overwrite,password)
     314static int do_extract_currentfile(uf,popt_extract_without_path,popt_overwrite,password)
    313315    unzFile uf;
    314316    const int* popt_extract_without_path;
     
    325327
    326328    unz_file_info64 file_info;
    327     uLong ratio=0;
    328329    err = unzGetCurrentFileInfo64(uf,&file_info,filename_inzip,sizeof(filename_inzip),NULL,0,NULL,0);
    329330
     
    440441                }
    441442                if (err>0)
    442                     if (fwrite(buf,err,1,fout)!=1)
     443                    if (fwrite(buf,(unsigned)err,1,fout)!=1)
    443444                    {
    444445                        printf("error in writing extracted file\n");
     
    473474
    474475
    475 int do_extract(uf,opt_extract_without_path,opt_overwrite,password)
     476static int do_extract(uf,opt_extract_without_path,opt_overwrite,password)
    476477    unzFile uf;
    477478    int opt_extract_without_path;
     
    482483    unz_global_info64 gi;
    483484    int err;
    484     FILE* fout=NULL;
    485485
    486486    err = unzGetGlobalInfo64(uf,&gi);
     
    509509}
    510510
    511 int do_extract_onefile(uf,filename,opt_extract_without_path,opt_overwrite,password)
     511static int do_extract_onefile(uf,filename,opt_extract_without_path,opt_overwrite,password)
    512512    unzFile uf;
    513513    const char* filename;
     
    516516    const char* password;
    517517{
    518     int err = UNZ_OK;
    519518    if (unzLocateFile(uf,filename,CASESENSITIVITY)!=UNZ_OK)
    520519    {
Note: See TracChangeset for help on using the changeset viewer.

© 2025 Oracle Support Privacy / Do Not Sell My Info Terms of Use Trademark Policy Automated Access Etiquette