VirtualBox

Ignore:
Timestamp:
Dec 16, 2019 5:58:08 PM (5 years ago)
Author:
vboxsync
svn:sync-xref-src-repo-rev:
135479
Message:

Runtime/zip.cpp: Allow RTZIPTYPE_ZLIB_NO_HEADER in the block decompression API

File:
1 edited

Legend:

Unmodified
Added
Removed
  • trunk/src/VBox/Runtime/common/zip/zip.cpp

    r76553 r82594  
    19351935
    19361936        case RTZIPTYPE_ZLIB:
     1937        case RTZIPTYPE_ZLIB_NO_HEADER:
    19371938        {
    19381939#ifdef RTZIP_USE_ZLIB
     
    19471948            ZStrm.avail_out = (uInt)cbDst;
    19481949
    1949             int rc = inflateInit(&ZStrm);
     1950            int rc;
     1951            if (enmType == RTZIPTYPE_ZLIB)
     1952                rc = inflateInit(&ZStrm);
     1953            else if (enmType == RTZIPTYPE_ZLIB_NO_HEADER)
     1954                rc = inflateInit2(&ZStrm, -Z_DEF_WBITS);
     1955            else
     1956                AssertFailedReturn(VERR_INTERNAL_ERROR);
     1957
    19501958            if (RT_UNLIKELY(rc != Z_OK))
    19511959                return zipErrConvertFromZlib(rc, false /*fCompressing*/);
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