VirtualBox

Changeset 95924 in vbox for trunk/src/VBox/Runtime/common


Ignore:
Timestamp:
Jul 28, 2022 10:46:52 PM (3 years ago)
Author:
vboxsync
Message:

IPRT/zip.cpp: Adjustments for IPRT_NO_CRT mode. Need to disable LZF then because it uses errno (cannot modify it either as using a system lzf lib is VBox build options). bugref:10261

File:
1 edited

Legend:

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

    r95807 r95924  
    3232#define RTZIP_USE_ZLIB 1
    3333//#define RTZIP_USE_BZLIB 1
    34 #ifndef IN_GUEST
     34#if !defined(IN_GUEST) && !defined(IPRT_NO_CRT)
    3535# define RTZIP_USE_LZF 1
    3636#endif
     
    11731173            if (cbOutput != cbUncompressed)
    11741174            {
     1175# ifndef IPRT_NO_CRT /* no errno */
    11751176                AssertMsgFailed(("Decompression error, errno=%d. cbOutput=%#x cbUncompressed=%#x\n",
    11761177                                 errno, cbOutput, cbUncompressed));
     1178# endif
    11771179                return VERR_GENERAL_FAILURE; /** @todo Get better error codes for RTZip! */
    11781180            }
     
    11861188            if (cbOutput != cbUncompressed)
    11871189            {
     1190# ifndef IPRT_NO_CRT /* no errno */
    11881191                AssertMsgFailed(("Decompression error, errno=%d. cbOutput=%#x cbUncompressed=%#x\n",
    11891192                                 errno, cbOutput, cbUncompressed));
     1193# endif
    11901194                return VERR_GENERAL_FAILURE; /** @todo Get better error codes for RTZip! */
    11911195            }
     
    18581862            if (RT_UNLIKELY(cbDstActual < 1))
    18591863            {
     1864# ifndef IPRT_NO_CRT /* no errno */
    18601865                if (errno == E2BIG)
    18611866                    return VERR_BUFFER_OVERFLOW;
    18621867                Assert(errno == EINVAL);
     1868# endif
    18631869                return VERR_GENERAL_FAILURE;
    18641870            }
Note: See TracChangeset for help on using the changeset viewer.

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