_ZNK4Ogre10DataStream4sizeEv:
  186|    369|        size_t size(void) const { return mSize; }

_ZN4Ogre13OptimisedUtilC2Ev:
   64|      2|        OptimisedUtil(void) {}

_ZNK4Ogre9SharedPtrINS_10DataStreamEEptEv:
   63|    738|        T* operator->() const { return shared_ptr<T>::operator->(); }

_ZN4Ogre14ArchiveManager12getSingletonEv:
   40|      1|    {  
   41|       |        assert( msSingleton );  return ( *msSingleton );  
   42|      1|    }
_ZN4Ogre14ArchiveManagerC2Ev:
   45|      1|    {
   46|      1|    }
_ZN4Ogre14ArchiveManager17addArchiveFactoryEPNS_14ArchiveFactoryE:
  126|      1|    {
  127|      1|        mArchFactories.emplace(factory->getType(), factory);
  128|      1|        LogManager::getSingleton().logMessage("ArchiveFactory for type '" + factory->getType() + "' registered");
  129|      1|    }

_ZN4Ogre16MemoryDataStreamC2EPvmbb:
  190|  3.83k|        : DataStream(static_cast<uint16>(readOnly ? READ : (READ | WRITE)))
  ------------------
  |  Branch (190:42): [True: 0, False: 3.83k]
  ------------------
  191|  3.83k|    {
  192|  3.83k|        mData = mPos = static_cast<uchar*>(pMem);
  193|  3.83k|        mSize = inSize;
  194|  3.83k|        mEnd = mData + mSize;
  195|  3.83k|        mFreeOnClose = freeOnClose;
  196|       |        assert(mEnd >= mPos);
  197|  3.83k|    }
_ZN4Ogre16MemoryDataStreamC2ERKNSt3__112basic_stringIcNS1_11char_traitsIcEENS1_9allocatorIcEEEEmbb:
  327|  1.57k|        : DataStream(name, static_cast<uint16>(readOnly ? READ : (READ | WRITE)))
  ------------------
  |  Branch (327:48): [True: 1.57k, False: 0]
  ------------------
  328|  1.57k|    {
  329|  1.57k|        mSize = inSize;
  330|  1.57k|        mData = OGRE_ALLOC_T(uchar, mSize, MEMCATEGORY_GENERAL);
  331|  1.57k|        mPos = mData;
  332|  1.57k|        mEnd = mData + mSize;
  333|  1.57k|        mFreeOnClose = freeOnClose;
  334|       |        assert(mEnd >= mPos);
  335|  1.57k|    }
_ZN4Ogre16MemoryDataStreamD2Ev:
  338|  5.40k|    {
  339|  5.40k|        close();
  340|  5.40k|    }
_ZN4Ogre16MemoryDataStream4readEPvm:
  343|    369|    {
  344|       |        // Read over end of memory?
  345|    369|        if (mPos >= mEnd)
  ------------------
  |  Branch (345:13): [True: 66, False: 303]
  ------------------
  346|     66|            return 0;
  347|    303|        size_t cnt = std::min(count, static_cast<size_t>(mEnd - mPos));
  348|    303|        if (cnt == 0)
  ------------------
  |  Branch (348:13): [True: 0, False: 303]
  ------------------
  349|      0|            return 0;
  350|       |
  351|    303|        assert (cnt<=count);
  352|       |
  353|    303|        memcpy(buf, mPos, cnt);
  354|    303|        mPos += cnt;
  355|    303|        return cnt;
  356|    303|    }
_ZN4Ogre16MemoryDataStream5closeEv:
  461|  5.40k|    {
  462|  5.40k|        mAccess = 0;
  463|  5.40k|        if (mFreeOnClose && mData)
  ------------------
  |  Branch (463:13): [True: 1.57k, False: 3.83k]
  |  Branch (463:29): [True: 1.57k, False: 0]
  ------------------
  464|  1.57k|        {
  465|       |            OGRE_FREE(mData, MEMCATEGORY_GENERAL);
  466|  1.57k|            mData = 0;
  467|  1.57k|        }
  468|  5.40k|    }

_ZN4Ogre9ExceptionC2EiRKNSt3__112basic_stringIcNS1_11char_traitsIcEENS1_9allocatorIcEEEES9_PKcSB_l:
   43|  3.01k|        line( lin ),
   44|  3.01k|        typeName(typ),
   45|  3.01k|        description( desc ),
   46|  3.01k|        source( src ),
   47|  3.01k|        file( fil )
   48|  3.01k|    {
   49|  3.01k|        StringStream ss;
   50|       |
   51|  3.01k|        ss << typeName << ": "
   52|  3.01k|           << description
   53|  3.01k|           << " in " << source;
   54|       |
   55|  3.01k|        if( line > 0 )
  ------------------
  |  Branch (55:13): [True: 3.01k, False: 0]
  ------------------
   56|  3.01k|        {
   57|  3.01k|            ss << " at " << file << " (line " << line << ")";
   58|  3.01k|        }
   59|       |
   60|  3.01k|        fullDesc = ss.str();
   61|  3.01k|    }

_ZN4Ogre3LogC2ERKNSt3__112basic_stringIcNS1_11char_traitsIcEENS1_9allocatorIcEEEEbb:
   52|      1|        mLogLevel(LML_NORMAL), mDebugOut(debuggerOutput),
   53|      1|        mSuppressFile(suppressFile), mTimeStamp(true), mLogName(name), mTermHasColours(false)
   54|      1|    {
   55|      1|        if (!mSuppressFile)
  ------------------
  |  Branch (55:13): [True: 0, False: 1]
  ------------------
   56|      0|        {
   57|      0|            mLog.open(name.c_str());
   58|       |
   59|       |#if (OGRE_PLATFORM == OGRE_PLATFORM_WIN32 || OGRE_PLATFORM == OGRE_PLATFORM_WINRT) && _WIN32_WINNT >= _WIN32_WINNT_VISTA
   60|       |            // Register log file to be collected by Windows Error Reporting
   61|       |            const int utf16Length = ::MultiByteToWideChar(CP_ACP, 0, name.c_str(), (int)name.size(), NULL, 0);
   62|       |            if(utf16Length > 0)
   63|       |            {
   64|       |                std::wstring wname;
   65|       |                wname.resize(utf16Length);
   66|       |                if (0 != ::MultiByteToWideChar(CP_ACP, 0, name.c_str(), (int)name.size(), &wname[0], (int)wname.size()))
   67|       |                    WerRegisterFile(wname.c_str(), WerRegFileTypeOther, WER_FILE_ANONYMOUS_DATA);
   68|       |            }
   69|       |#endif
   70|      0|        }
   71|       |
   72|      1|#if OGRE_PLATFORM != OGRE_PLATFORM_WINRT
   73|      1|        char* val = getenv("OGRE_MIN_LOGLEVEL");
   74|      1|        int min_lml;
   75|      1|        if(val && StringConverter::parse(val, min_lml))
  ------------------
  |  Branch (75:12): [True: 0, False: 1]
  |  Branch (75:12): [True: 0, False: 1]
  |  Branch (75:19): [True: 0, False: 0]
  ------------------
   76|      0|            setMinLogLevel(LogMessageLevel(min_lml));
   77|       |
   78|      1|        if(mDebugOut)
  ------------------
  |  Branch (78:12): [True: 0, False: 1]
  ------------------
   79|      0|        {
   80|      0|            val = getenv("TERM");
   81|      0|            mTermHasColours = val && String(val).find("xterm") != String::npos;
  ------------------
  |  Branch (81:31): [True: 0, False: 0]
  |  Branch (81:38): [True: 0, False: 0]
  ------------------
   82|      0|        }
   83|      1|#endif
   84|      1|    }
_ZN4Ogre3Log10logMessageERKNSt3__112basic_stringIcNS1_11char_traitsIcEENS1_9allocatorIcEEEENS_15LogMessageLevelEb:
   97|      4|    {
   98|      4|        OGRE_LOCK_AUTO_MUTEX;
   99|      4|        if (lml >= mLogLevel)
  ------------------
  |  Branch (99:13): [True: 0, False: 4]
  ------------------
  100|      0|        {
  101|      0|            bool skipThisMessage = false;
  102|      0|            for(auto & l : mListeners)
  ------------------
  |  Branch (102:26): [True: 0, False: 0]
  ------------------
  103|      0|                l->messageLogged( message, lml, maskDebug, mLogName, skipThisMessage);
  104|       |            
  105|      0|            if (!skipThisMessage)
  ------------------
  |  Branch (105:17): [True: 0, False: 0]
  ------------------
  106|      0|            {
  107|      0|                if (mDebugOut && !maskDebug)
  ------------------
  |  Branch (107:21): [True: 0, False: 0]
  |  Branch (107:34): [True: 0, False: 0]
  ------------------
  108|      0|                {
  109|       |#    if (OGRE_PLATFORM == OGRE_PLATFORM_WIN32 || OGRE_PLATFORM == OGRE_PLATFORM_WINRT) && OGRE_DEBUG_MODE
  110|       |                    OutputDebugStringA("Ogre: ");
  111|       |                    OutputDebugStringA(message.c_str());
  112|       |                    OutputDebugStringA("\n");
  113|       |#    endif
  114|       |
  115|      0|                    std::ostream& os = int(lml) >= int(LML_WARNING) ? std::cerr : std::cout;
  ------------------
  |  Branch (115:40): [True: 0, False: 0]
  ------------------
  116|       |
  117|      0|                    if(mTermHasColours) {
  ------------------
  |  Branch (117:24): [True: 0, False: 0]
  ------------------
  118|      0|                        if(lml == LML_WARNING)
  ------------------
  |  Branch (118:28): [True: 0, False: 0]
  ------------------
  119|      0|                            os << YELLOW;
  120|      0|                        if(lml == LML_CRITICAL)
  ------------------
  |  Branch (120:28): [True: 0, False: 0]
  ------------------
  121|      0|                            os << RED;
  122|      0|                    }
  123|       |
  124|      0|                    os << message;
  125|       |
  126|      0|                    if(mTermHasColours) {
  ------------------
  |  Branch (126:24): [True: 0, False: 0]
  ------------------
  127|      0|                        os << RESET;
  128|      0|                    }
  129|       |
  130|      0|                    os << std::endl;
  131|      0|                }
  132|       |
  133|       |                // Write time into log
  134|      0|                if (!mSuppressFile)
  ------------------
  |  Branch (134:21): [True: 0, False: 0]
  ------------------
  135|      0|                {
  136|      0|                    if (mTimeStamp)
  ------------------
  |  Branch (136:25): [True: 0, False: 0]
  ------------------
  137|      0|                    {
  138|      0|                        auto t = std::time(nullptr);
  139|      0|                        auto pTime = std::localtime(&t);
  140|      0|                        mLog << std::put_time(pTime, "%H:%M:%S: ");
  141|      0|                    }
  142|      0|                    mLog << message << std::endl;
  143|       |
  144|       |                    // Flush stcmdream to ensure it is written (incase of a crash, we need log to be up to date)
  145|      0|                    mLog.flush();
  146|      0|                }
  147|      0|            }
  148|      0|        }
  149|      4|    }
_ZN4Ogre3Log14setMinLogLevelENS_15LogMessageLevelE:
  173|      1|    {
  174|      1|        OGRE_LOCK_AUTO_MUTEX;
  175|      1|        mLogLevel = lml;
  176|      1|    }

_ZN4Ogre10LogManager12getSingletonEv:
   39|      4|    {  
   40|       |        assert( msSingleton );  return ( *msSingleton );  
   41|      4|    }
_ZN4Ogre10LogManagerC2Ev:
   44|      1|    {
   45|       |        mDefaultLog = NULL;
   46|      1|    }
_ZN4Ogre10LogManager9createLogERKNSt3__112basic_stringIcNS1_11char_traitsIcEENS1_9allocatorIcEEEEbbb:
   61|      1|    {
   62|      1|        OGRE_LOCK_AUTO_MUTEX;
   63|       |
   64|      1|        Log* newLog = OGRE_NEW Log(name, debuggerOutput, suppressFileOutput);
   65|       |
   66|      1|        if( !mDefaultLog || defaultLog )
  ------------------
  |  Branch (66:13): [True: 1, False: 0]
  |  Branch (66:29): [True: 0, False: 0]
  ------------------
   67|      1|        {
   68|      1|            mDefaultLog = newLog;
   69|      1|        }
   70|       |
   71|      1|        mLogs.emplace(name, newLog);
   72|       |
   73|      1|        return newLog;
   74|      1|    }
_ZN4Ogre10LogManager10logMessageERKNSt3__112basic_stringIcNS1_11char_traitsIcEENS1_9allocatorIcEEEENS_15LogMessageLevelEb:
  125|      4|    {
  126|      4|        OGRE_LOCK_AUTO_MUTEX;
  127|      4|        if (mDefaultLog)
  ------------------
  |  Branch (127:13): [True: 4, False: 0]
  ------------------
  128|      4|        {
  129|      4|            mDefaultLog->logMessage(message, lml, maskDebug);
  130|      4|        }
  131|      4|    }
_ZN4Ogre10LogManager14setMinLogLevelENS_15LogMessageLevelE:
  155|      1|    {
  156|      1|        OGRE_LOCK_AUTO_MUTEX;
  157|      1|        if (mDefaultLog)
  ------------------
  |  Branch (157:13): [True: 1, False: 0]
  ------------------
  158|      1|        {
  159|      1|            mDefaultLog->setMinLogLevel(lml);
  160|      1|        }
  161|      1|    }

_ZN4Ogre13OptimisedUtil21_detectImplementationEv:
  326|      2|    {
  327|       |        //
  328|       |        // Some speed test results (averaged number of CPU timestamp (RDTSC) per-function call):
  329|       |        //
  330|       |        //   Dagon SkeletonAnimation sample - softwareVertexSkinning:
  331|       |        //
  332|       |        //                                      Pentium 4 3.0G HT       Athlon XP 2500+     Athlon 64 X2 Dual Core 3800+
  333|       |        //
  334|       |        //      Shared Buffers, General C       763677                  462903              473038
  335|       |        //      Shared Buffers, Unrolled SSE    210030 *best*           369762              228328 *best*
  336|       |        //      Shared Buffers, General SSE     286202                  352412 *best*       302796
  337|       |        //
  338|       |        //      Separated Buffers, General C    762640                  464840              478740
  339|       |        //      Separated Buffers, Unrolled SSE 219222 *best*           287992 *best*       238770 *best*
  340|       |        //      Separated Buffers, General SSE  290129                  341614              307262
  341|       |        //
  342|       |        //      PosOnly, General C              388663                  257350              262831
  343|       |        //      PosOnly, Unrolled SSE           139814 *best*           200323 *best*       168995 *best*
  344|       |        //      PosOnly, General SSE            172693                  213704              175447
  345|       |        //
  346|       |        //   Another my own test scene - softwareVertexSkinning:
  347|       |        //
  348|       |        //                                      Pentium P4 3.0G HT      Athlon XP 2500+
  349|       |        //
  350|       |        //      Shared Buffers, General C       74527                   -
  351|       |        //      Shared Buffers, Unrolled SSE    22743 *best*            -
  352|       |        //      Shared Buffers, General SSE     28527                   -
  353|       |        //
  354|       |        //
  355|       |        // Note that speed test appears unaligned load/store instruction version
  356|       |        // loss performance 5%-10% than aligned load/store version, even if both
  357|       |        // of them access to aligned data. Thus, we should use aligned load/store
  358|       |        // as soon as possible.
  359|       |        //
  360|       |        //
  361|       |        // We are pick up the implementation based on test results above.
  362|       |        //
  363|       |#ifdef __DO_PROFILE__
  364|       |        {
  365|       |            static OptimisedUtilProfiler msOptimisedUtilProfiler;
  366|       |            return &msOptimisedUtilProfiler;
  367|       |        }
  368|       |
  369|       |#else   // !__DO_PROFILE__
  370|       |
  371|      2|#if __OGRE_HAVE_SSE
  372|      2|        if (PlatformInformation::getCpuFeatures() & PlatformInformation::CPU_FEATURE_SSE)
  ------------------
  |  Branch (372:13): [True: 2, False: 0]
  ------------------
  373|      2|        {
  374|      2|            return _getOptimisedUtilSSE();
  375|      2|        }
  376|      0|        else
  377|       |#elif __OGRE_HAVE_NEON
  378|       |        if (PlatformInformation::getCpuFeatures() & PlatformInformation::CPU_FEATURE_NEON)
  379|       |        {
  380|       |            return _getOptimisedUtilSSE();
  381|       |        }
  382|       |        else
  383|       |#endif  // __OGRE_HAVE_SSE
  384|      0|        {
  385|      0|            return _getOptimisedUtilGeneral();
  386|      0|        }
  387|       |
  388|      2|#endif  // __DO_PROFILE__
  389|      2|    }

_ZN4Ogre16OptimisedUtilSSEC2Ev:
 1040|      2|        : mPreferGeneralVersionForSharedBuffers(false)
 1041|      2|    {
 1042|       |        // For AMD Athlon XP (but not that for Althon 64), it's prefer to never use
 1043|       |        // unrolled version for shared buffers at all, I guess because that version
 1044|       |        // run out of usable CPU registers, or L1/L2 cache related problem, causing
 1045|       |        // slight performance loss than general version.
 1046|       |        //
 1047|      2|#if __OGRE_HAVE_NEON == 0
 1048|      2|        if (PlatformInformation::getCpuIdentifier().find("AuthenticAMD") != String::npos)
  ------------------
  |  Branch (1048:13): [True: 0, False: 2]
  ------------------
 1049|      0|        {
 1050|       |            // How can I check it's an Athlon XP but not Althon 64?
 1051|       |            // Ok, just test whether supports SSE2/SSE3 or not, if not,
 1052|       |            // assume general version faster than unrolled version :)
 1053|       |            //
 1054|      0|            if (!(PlatformInformation::getCpuFeatures() &
  ------------------
  |  Branch (1054:17): [True: 0, False: 0]
  ------------------
 1055|      0|                (PlatformInformation::CPU_FEATURE_SSE2 | PlatformInformation::CPU_FEATURE_SSE3)))
 1056|      0|            {
 1057|      0|                mPreferGeneralVersionForSharedBuffers = true;
 1058|      0|            }
 1059|      0|        }
 1060|      2|#endif
 1061|      2|    }
_ZN4Ogre20_getOptimisedUtilSSEEv:
 2141|      2|    {
 2142|      2|        static OptimisedUtilSSE msOptimisedUtilSSE;
 2143|       |#if defined(__OGRE_SIMD_ALIGN_STACK)
 2144|       |        static OptimisedUtilWithStackAlign msOptimisedUtilWithStackAlign(&msOptimisedUtilSSE);
 2145|       |        return &msOptimisedUtilWithStackAlign;
 2146|       |#else
 2147|      2|        return &msOptimisedUtilSSE;
 2148|      2|#endif
 2149|      2|    }

_ZN4Ogre19PlatformInformation16getCpuIdentifierEv:
  655|      2|    {
  656|      2|        static const String sIdentifier = _detectCpuIdentifier();
  657|      2|        return sIdentifier;
  658|      2|    }
_ZN4Ogre19PlatformInformation14getCpuFeaturesEv:
  661|      2|    {
  662|      2|        static const uint sFeatures = _detectCpuFeatures();
  663|      2|        return sFeatures;
  664|      2|    }
OgrePlatformInformation.cpp:_ZN4OgreL20_detectCpuIdentifierEv:
  427|      2|    {
  428|       |        // Supports CPUID instruction ?
  429|      2|        if (_isSupportCpuid())
  ------------------
  |  Branch (429:13): [True: 2, False: 0]
  ------------------
  430|      2|        {
  431|      2|            CpuidResult result;
  432|      2|            uint nExIds;
  433|      2|            char CPUString[0x20];
  434|      2|            char CPUBrandString[0x40];
  435|       |
  436|      2|            StringStream detailedIdentStr;
  437|       |
  438|       |
  439|       |            // Has standard feature ?
  440|      2|            if (_performCpuid(0, result))
  ------------------
  |  Branch (440:17): [True: 2, False: 0]
  ------------------
  441|      2|            {
  442|      2|                memset(CPUString, 0, sizeof(CPUString));
  443|      2|                memset(CPUBrandString, 0, sizeof(CPUBrandString));
  444|       |
  445|       |                //*((int*)CPUString) = result._ebx;
  446|       |                //*((int*)(CPUString+4)) = result._edx;
  447|       |                //*((int*)(CPUString+8)) = result._ecx;
  448|      2|                memcpy(CPUString, &result._ebx, sizeof(int));
  449|      2|                memcpy(CPUString+4, &result._edx, sizeof(int));
  450|      2|                memcpy(CPUString+8, &result._ecx, sizeof(int));
  451|       |
  452|      2|                detailedIdentStr << CPUString;
  453|       |
  454|       |                // Calling _performCpuid with 0x80000000 as the query argument
  455|       |                // gets the number of valid extended IDs.
  456|      2|                nExIds = _performCpuid(0x80000000, result);
  457|       |
  458|     20|                for (uint i=0x80000000; i<=nExIds; ++i)
  ------------------
  |  Branch (458:41): [True: 18, False: 2]
  ------------------
  459|     18|                {
  460|     18|                    _performCpuid(i, result);
  461|       |
  462|       |                    // Interpret CPU brand string and cache information.
  463|     18|                    if  (i == 0x80000002)
  ------------------
  |  Branch (463:26): [True: 2, False: 16]
  ------------------
  464|      2|                    {
  465|      2|                        memcpy(CPUBrandString + 0, &result._eax, sizeof(result._eax));
  466|      2|                        memcpy(CPUBrandString + 4, &result._ebx, sizeof(result._ebx));
  467|      2|                        memcpy(CPUBrandString + 8, &result._ecx, sizeof(result._ecx));
  468|      2|                        memcpy(CPUBrandString + 12, &result._edx, sizeof(result._edx));
  469|      2|                    }
  470|     16|                    else if  (i == 0x80000003)
  ------------------
  |  Branch (470:31): [True: 2, False: 14]
  ------------------
  471|      2|                    {
  472|      2|                        memcpy(CPUBrandString + 16 + 0, &result._eax, sizeof(result._eax));
  473|      2|                        memcpy(CPUBrandString + 16 + 4, &result._ebx, sizeof(result._ebx));
  474|      2|                        memcpy(CPUBrandString + 16 + 8, &result._ecx, sizeof(result._ecx));
  475|      2|                        memcpy(CPUBrandString + 16 + 12, &result._edx, sizeof(result._edx));
  476|      2|                    }
  477|     14|                    else if  (i == 0x80000004)
  ------------------
  |  Branch (477:31): [True: 2, False: 12]
  ------------------
  478|      2|                    {
  479|      2|                        memcpy(CPUBrandString + 32 + 0, &result._eax, sizeof(result._eax));
  480|      2|                        memcpy(CPUBrandString + 32 + 4, &result._ebx, sizeof(result._ebx));
  481|      2|                        memcpy(CPUBrandString + 32 + 8, &result._ecx, sizeof(result._ecx));
  482|      2|                        memcpy(CPUBrandString + 32 + 12, &result._edx, sizeof(result._edx));
  483|      2|                    }
  484|     18|                }
  485|       |
  486|      2|                String brand(CPUBrandString);
  487|      2|                StringUtil::trim(brand);
  488|      2|                if (!brand.empty())
  ------------------
  |  Branch (488:21): [True: 2, False: 0]
  ------------------
  489|      2|                    detailedIdentStr << ": " << brand;
  490|       |
  491|      2|                return detailedIdentStr.str();
  492|      2|            }
  493|      2|        }
  494|       |
  495|      0|        return "X86";
  496|      2|    }
OgrePlatformInformation.cpp:_ZN4OgreL13_performCpuidEiRNS_11CpuidResultE:
  151|     30|    {
  152|       |#if OGRE_COMPILER == OGRE_COMPILER_MSVC
  153|       |        int CPUInfo[4];
  154|       |        __cpuid(CPUInfo, query);
  155|       |        result._eax = CPUInfo[0];
  156|       |        result._ebx = CPUInfo[1];
  157|       |        result._ecx = CPUInfo[2];
  158|       |        result._edx = CPUInfo[3];
  159|       |        return result._eax;
  160|       |#elif (OGRE_COMPILER == OGRE_COMPILER_GNUC || OGRE_COMPILER == OGRE_COMPILER_CLANG) && OGRE_PLATFORM != OGRE_PLATFORM_EMSCRIPTEN
  161|       |        #if OGRE_ARCH_TYPE == OGRE_ARCHITECTURE_64
  162|     30|        __asm__
  163|     30|        (
  164|     30|            "cpuid": "=a" (result._eax), "=b" (result._ebx), "=c" (result._ecx), "=d" (result._edx) : "a" (query)
  165|     30|        );
  166|       |        #else
  167|       |        __asm__
  168|       |        (
  169|       |            "pushl  %%ebx           \n\t"
  170|       |            "cpuid                  \n\t"
  171|       |            "movl   %%ebx, %%edi    \n\t"
  172|       |            "popl   %%ebx           \n\t"
  173|       |            : "=a" (result._eax), "=D" (result._ebx), "=c" (result._ecx), "=d" (result._edx)
  174|       |            : "a" (query)
  175|       |        );
  176|       |       #endif // OGRE_ARCHITECTURE_64
  177|     30|        return result._eax;
  178|       |
  179|       |#else
  180|       |        // TODO: Supports other compiler
  181|       |        return 0;
  182|       |#endif
  183|     30|    }
OgrePlatformInformation.cpp:_ZN4OgreL18_detectCpuFeaturesEv:
  408|      2|    {
  409|      2|        uint features = queryCpuFeatures();
  410|       |
  411|      2|        const uint sse_features = 0
  412|      2|            | PlatformInformation::CPU_FEATURE_SSE
  413|      2|            | PlatformInformation::CPU_FEATURE_SSE2
  414|      2|            | PlatformInformation::CPU_FEATURE_SSE3
  415|      2|            | PlatformInformation::CPU_FEATURE_SSE41
  416|      2|            | PlatformInformation::CPU_FEATURE_SSE42;
  417|       |
  418|      2|        if ((features & sse_features) && !_checkOperatingSystemSupportSSE())
  ------------------
  |  Branch (418:13): [True: 2, False: 0]
  |  Branch (418:42): [True: 0, False: 2]
  ------------------
  419|      0|        {
  420|      0|            features &= ~sse_features;
  421|      0|        }
  422|       |
  423|      2|        return features;
  424|      2|    }
OgrePlatformInformation.cpp:_ZN4OgreL16queryCpuFeaturesEv:
  266|      2|    {
  267|       |
  268|      2|#define CPUID_FUNC_VENDOR_ID                 0x0
  269|      2|#define CPUID_FUNC_STANDARD_FEATURES         0x1
  270|      2|#define CPUID_FUNC_EXTENSION_QUERY           0x80000000
  271|      2|#define CPUID_FUNC_EXTENDED_FEATURES         0x80000001
  272|      2|#define CPUID_FUNC_ADVANCED_POWER_MANAGEMENT 0x80000007
  273|       |
  274|      2|#define CPUID_STD_FPU               (1<<0)
  275|      2|#define CPUID_STD_TSC               (1<<4)
  276|      2|#define CPUID_STD_CMOV              (1<<15)
  277|      2|#define CPUID_STD_MMX               (1<<23)
  278|      2|#define CPUID_STD_SSE               (1<<25)
  279|      2|#define CPUID_STD_SSE2              (1<<26)
  280|      2|#define CPUID_STD_HTT               (1<<28)     // EDX[28] - Bit 28 set indicates  Hyper-Threading Technology is supported in hardware.
  281|       |
  282|      2|#define CPUID_STD_SSE3              (1<<0)      // ECX[0]  - Bit 0 of standard function 1 indicate SSE3 supported
  283|      2|#define CPUID_STD_SSE41             (1<<19)     // ECX[19] - Bit 0 of standard function 1 indicate SSE41 supported
  284|      2|#define CPUID_STD_SSE42             (1<<20)     // ECX[20] - Bit 0 of standard function 1 indicate SSE42 supported
  285|       |
  286|      2|#define CPUID_FAMILY_ID_MASK        0x0F00      // EAX[11:8] - Bit 11 thru 8 contains family  processor id
  287|      2|#define CPUID_EXT_FAMILY_ID_MASK    0x0F00000   // EAX[23:20] - Bit 23 thru 20 contains extended family processor id
  288|      2|#define CPUID_PENTIUM4_ID           0x0F00      // Pentium 4 family processor id
  289|       |
  290|      2|#define CPUID_EXT_3DNOW             (1<<31)
  291|      2|#define CPUID_EXT_AMD_3DNOWEXT      (1<<30)
  292|      2|#define CPUID_EXT_AMD_MMXEXT        (1<<22)
  293|       |
  294|       |
  295|      2|#define CPUID_APM_INVARIANT_TSC     (1<<8)      // EDX[8] - Bit 8 of function 0x80000007 indicates support for invariant TSC.
  296|       |
  297|      2|        uint features = 0;
  298|       |
  299|       |        // Supports CPUID instruction ?
  300|      2|        if (_isSupportCpuid())
  ------------------
  |  Branch (300:13): [True: 2, False: 0]
  ------------------
  301|      2|        {
  302|      2|            CpuidResult result;
  303|       |
  304|       |            // Has standard feature ?
  305|      2|            if (_performCpuid(CPUID_FUNC_VENDOR_ID, result))
  ------------------
  |  |  268|      2|#define CPUID_FUNC_VENDOR_ID                 0x0
  ------------------
  |  Branch (305:17): [True: 2, False: 0]
  ------------------
  306|      2|            {
  307|       |                // Check vendor strings
  308|      2|                if (memcmp(&result._ebx, "GenuineIntel", 12) == 0)
  ------------------
  |  Branch (308:21): [True: 2, False: 0]
  ------------------
  309|      2|                {
  310|      2|                    if (result._eax > 2)
  ------------------
  |  Branch (310:25): [True: 2, False: 0]
  ------------------
  311|      2|                        features |= PlatformInformation::CPU_FEATURE_PRO;
  312|       |
  313|       |                    // Check standard feature
  314|      2|                    _performCpuid(CPUID_FUNC_STANDARD_FEATURES, result);
  ------------------
  |  |  269|      2|#define CPUID_FUNC_STANDARD_FEATURES         0x1
  ------------------
  315|       |
  316|      2|                    if (result._edx & CPUID_STD_FPU)
  ------------------
  |  |  274|      2|#define CPUID_STD_FPU               (1<<0)
  ------------------
  |  Branch (316:25): [True: 2, False: 0]
  ------------------
  317|      2|                        features |= PlatformInformation::CPU_FEATURE_FPU;
  318|      2|                    if (result._edx & CPUID_STD_TSC)
  ------------------
  |  |  275|      2|#define CPUID_STD_TSC               (1<<4)
  ------------------
  |  Branch (318:25): [True: 2, False: 0]
  ------------------
  319|      2|                        features |= PlatformInformation::CPU_FEATURE_TSC;
  320|      2|                    if (result._edx & CPUID_STD_CMOV)
  ------------------
  |  |  276|      2|#define CPUID_STD_CMOV              (1<<15)
  ------------------
  |  Branch (320:25): [True: 2, False: 0]
  ------------------
  321|      2|                        features |= PlatformInformation::CPU_FEATURE_CMOV;
  322|      2|                    if (result._edx & CPUID_STD_MMX)
  ------------------
  |  |  277|      2|#define CPUID_STD_MMX               (1<<23)
  ------------------
  |  Branch (322:25): [True: 2, False: 0]
  ------------------
  323|      2|                        features |= PlatformInformation::CPU_FEATURE_MMX;
  324|      2|                    if (result._edx & CPUID_STD_SSE)
  ------------------
  |  |  278|      2|#define CPUID_STD_SSE               (1<<25)
  ------------------
  |  Branch (324:25): [True: 2, False: 0]
  ------------------
  325|      2|                        features |= PlatformInformation::CPU_FEATURE_MMXEXT | PlatformInformation::CPU_FEATURE_SSE;
  326|      2|                    if (result._edx & CPUID_STD_SSE2)
  ------------------
  |  |  279|      2|#define CPUID_STD_SSE2              (1<<26)
  ------------------
  |  Branch (326:25): [True: 2, False: 0]
  ------------------
  327|      2|                        features |= PlatformInformation::CPU_FEATURE_SSE2;
  328|      2|                    if (result._ecx & CPUID_STD_SSE3)
  ------------------
  |  |  282|      2|#define CPUID_STD_SSE3              (1<<0)      // ECX[0]  - Bit 0 of standard function 1 indicate SSE3 supported
  ------------------
  |  Branch (328:25): [True: 2, False: 0]
  ------------------
  329|      2|                        features |= PlatformInformation::CPU_FEATURE_SSE3;
  330|      2|                    if (result._ecx & CPUID_STD_SSE41)
  ------------------
  |  |  283|      2|#define CPUID_STD_SSE41             (1<<19)     // ECX[19] - Bit 0 of standard function 1 indicate SSE41 supported
  ------------------
  |  Branch (330:25): [True: 2, False: 0]
  ------------------
  331|      2|                        features |= PlatformInformation::CPU_FEATURE_SSE41;
  332|      2|                    if (result._ecx & CPUID_STD_SSE42)
  ------------------
  |  |  284|      2|#define CPUID_STD_SSE42             (1<<20)     // ECX[20] - Bit 0 of standard function 1 indicate SSE42 supported
  ------------------
  |  Branch (332:25): [True: 2, False: 0]
  ------------------
  333|      2|                        features |= PlatformInformation::CPU_FEATURE_SSE42;
  334|       |
  335|       |                    // Check to see if this is a Pentium 4 or later processor
  336|      2|                    if ((result._eax & CPUID_EXT_FAMILY_ID_MASK) ||
  ------------------
  |  |  287|      2|#define CPUID_EXT_FAMILY_ID_MASK    0x0F00000   // EAX[23:20] - Bit 23 thru 20 contains extended family processor id
  ------------------
  |  Branch (336:25): [True: 0, False: 2]
  ------------------
  337|      2|                        (result._eax & CPUID_FAMILY_ID_MASK) == CPUID_PENTIUM4_ID)
  ------------------
  |  |  286|      2|#define CPUID_FAMILY_ID_MASK        0x0F00      // EAX[11:8] - Bit 11 thru 8 contains family  processor id
  ------------------
                                      (result._eax & CPUID_FAMILY_ID_MASK) == CPUID_PENTIUM4_ID)
  ------------------
  |  |  288|      2|#define CPUID_PENTIUM4_ID           0x0F00      // Pentium 4 family processor id
  ------------------
  |  Branch (337:25): [True: 0, False: 2]
  ------------------
  338|      0|                    {
  339|       |                        // Check hyper-threading technology
  340|      0|                        if (result._edx & CPUID_STD_HTT)
  ------------------
  |  |  280|      0|#define CPUID_STD_HTT               (1<<28)     // EDX[28] - Bit 28 set indicates  Hyper-Threading Technology is supported in hardware.
  ------------------
  |  Branch (340:29): [True: 0, False: 0]
  ------------------
  341|      0|                            features |= PlatformInformation::CPU_FEATURE_HTT;
  342|      0|                    }
  343|       |
  344|       |
  345|      2|                    const uint maxExtensionFunctionSupport = _performCpuid(CPUID_FUNC_EXTENSION_QUERY, result);
  ------------------
  |  |  270|      2|#define CPUID_FUNC_EXTENSION_QUERY           0x80000000
  ------------------
  346|      2|                    if (maxExtensionFunctionSupport >= CPUID_FUNC_ADVANCED_POWER_MANAGEMENT)
  ------------------
  |  |  272|      2|#define CPUID_FUNC_ADVANCED_POWER_MANAGEMENT 0x80000007
  ------------------
  |  Branch (346:25): [True: 2, False: 0]
  ------------------
  347|      2|                    {
  348|      2|                        _performCpuid(CPUID_FUNC_ADVANCED_POWER_MANAGEMENT, result);
  ------------------
  |  |  272|      2|#define CPUID_FUNC_ADVANCED_POWER_MANAGEMENT 0x80000007
  ------------------
  349|       |
  350|      2|                        if (result._edx & CPUID_APM_INVARIANT_TSC)
  ------------------
  |  |  295|      2|#define CPUID_APM_INVARIANT_TSC     (1<<8)      // EDX[8] - Bit 8 of function 0x80000007 indicates support for invariant TSC.
  ------------------
  |  Branch (350:29): [True: 2, False: 0]
  ------------------
  351|      2|                            features |= PlatformInformation::CPU_FEATURE_INVARIANT_TSC;
  352|      2|                    }
  353|      2|                }
  354|      0|                else if (memcmp(&result._ebx, "AuthenticAMD", 12) == 0)
  ------------------
  |  Branch (354:26): [True: 0, False: 0]
  ------------------
  355|      0|                {
  356|      0|                    features |= PlatformInformation::CPU_FEATURE_PRO;
  357|       |
  358|       |                    // Check standard feature
  359|      0|                    _performCpuid(CPUID_FUNC_STANDARD_FEATURES, result);
  ------------------
  |  |  269|      0|#define CPUID_FUNC_STANDARD_FEATURES         0x1
  ------------------
  360|       |
  361|      0|                    if (result._edx & CPUID_STD_FPU)
  ------------------
  |  |  274|      0|#define CPUID_STD_FPU               (1<<0)
  ------------------
  |  Branch (361:25): [True: 0, False: 0]
  ------------------
  362|      0|                        features |= PlatformInformation::CPU_FEATURE_FPU;
  363|      0|                    if (result._edx & CPUID_STD_TSC)
  ------------------
  |  |  275|      0|#define CPUID_STD_TSC               (1<<4)
  ------------------
  |  Branch (363:25): [True: 0, False: 0]
  ------------------
  364|      0|                        features |= PlatformInformation::CPU_FEATURE_TSC;
  365|      0|                    if (result._edx & CPUID_STD_CMOV)
  ------------------
  |  |  276|      0|#define CPUID_STD_CMOV              (1<<15)
  ------------------
  |  Branch (365:25): [True: 0, False: 0]
  ------------------
  366|      0|                        features |= PlatformInformation::CPU_FEATURE_CMOV;
  367|      0|                    if (result._edx & CPUID_STD_MMX)
  ------------------
  |  |  277|      0|#define CPUID_STD_MMX               (1<<23)
  ------------------
  |  Branch (367:25): [True: 0, False: 0]
  ------------------
  368|      0|                        features |= PlatformInformation::CPU_FEATURE_MMX;
  369|      0|                    if (result._edx & CPUID_STD_SSE)
  ------------------
  |  |  278|      0|#define CPUID_STD_SSE               (1<<25)
  ------------------
  |  Branch (369:25): [True: 0, False: 0]
  ------------------
  370|      0|                        features |= PlatformInformation::CPU_FEATURE_SSE;
  371|      0|                    if (result._edx & CPUID_STD_SSE2)
  ------------------
  |  |  279|      0|#define CPUID_STD_SSE2              (1<<26)
  ------------------
  |  Branch (371:25): [True: 0, False: 0]
  ------------------
  372|      0|                        features |= PlatformInformation::CPU_FEATURE_SSE2;
  373|       |
  374|      0|                    if (result._ecx & CPUID_STD_SSE3)
  ------------------
  |  |  282|      0|#define CPUID_STD_SSE3              (1<<0)      // ECX[0]  - Bit 0 of standard function 1 indicate SSE3 supported
  ------------------
  |  Branch (374:25): [True: 0, False: 0]
  ------------------
  375|      0|                        features |= PlatformInformation::CPU_FEATURE_SSE3;
  376|       |
  377|       |                    // Has extended feature ?
  378|      0|                    const uint maxExtensionFunctionSupport = _performCpuid(CPUID_FUNC_EXTENSION_QUERY, result);
  ------------------
  |  |  270|      0|#define CPUID_FUNC_EXTENSION_QUERY           0x80000000
  ------------------
  379|      0|                    if (maxExtensionFunctionSupport >= CPUID_FUNC_EXTENDED_FEATURES)
  ------------------
  |  |  271|      0|#define CPUID_FUNC_EXTENDED_FEATURES         0x80000001
  ------------------
  |  Branch (379:25): [True: 0, False: 0]
  ------------------
  380|      0|                    {
  381|       |                        // Check extended feature
  382|      0|                        _performCpuid(CPUID_FUNC_EXTENDED_FEATURES, result);
  ------------------
  |  |  271|      0|#define CPUID_FUNC_EXTENDED_FEATURES         0x80000001
  ------------------
  383|       |
  384|      0|                        if (result._edx & CPUID_EXT_3DNOW)
  ------------------
  |  |  290|      0|#define CPUID_EXT_3DNOW             (1<<31)
  ------------------
  |  Branch (384:29): [True: 0, False: 0]
  ------------------
  385|      0|                            features |= PlatformInformation::CPU_FEATURE_3DNOW;
  386|      0|                        if (result._edx & CPUID_EXT_AMD_3DNOWEXT)
  ------------------
  |  |  291|      0|#define CPUID_EXT_AMD_3DNOWEXT      (1<<30)
  ------------------
  |  Branch (386:29): [True: 0, False: 0]
  ------------------
  387|      0|                            features |= PlatformInformation::CPU_FEATURE_3DNOWEXT;
  388|      0|                        if (result._edx & CPUID_EXT_AMD_MMXEXT)
  ------------------
  |  |  292|      0|#define CPUID_EXT_AMD_MMXEXT        (1<<22)
  ------------------
  |  Branch (388:29): [True: 0, False: 0]
  ------------------
  389|      0|                            features |= PlatformInformation::CPU_FEATURE_MMXEXT;
  390|      0|                    }
  391|       |
  392|       |
  393|      0|                    if (maxExtensionFunctionSupport >= CPUID_FUNC_ADVANCED_POWER_MANAGEMENT)
  ------------------
  |  |  272|      0|#define CPUID_FUNC_ADVANCED_POWER_MANAGEMENT 0x80000007
  ------------------
  |  Branch (393:25): [True: 0, False: 0]
  ------------------
  394|      0|                    {
  395|      0|                        _performCpuid(CPUID_FUNC_ADVANCED_POWER_MANAGEMENT, result);
  ------------------
  |  |  272|      0|#define CPUID_FUNC_ADVANCED_POWER_MANAGEMENT 0x80000007
  ------------------
  396|       |
  397|      0|                        if (result._edx & CPUID_APM_INVARIANT_TSC)
  ------------------
  |  |  295|      0|#define CPUID_APM_INVARIANT_TSC     (1<<8)      // EDX[8] - Bit 8 of function 0x80000007 indicates support for invariant TSC.
  ------------------
  |  Branch (397:29): [True: 0, False: 0]
  ------------------
  398|      0|                            features |= PlatformInformation::CPU_FEATURE_INVARIANT_TSC;
  399|      0|                    }
  400|      0|                }
  401|      2|            }
  402|      2|        }
  403|       |
  404|      2|        return features;
  405|      2|    }
OgrePlatformInformation.cpp:_ZN4OgreL31_checkOperatingSystemSupportSSEEv:
  202|      2|    {
  203|       |#if OGRE_COMPILER == OGRE_COMPILER_MSVC
  204|       |        /*
  205|       |            The FP part of SSE introduces a new architectural state and therefore
  206|       |            requires support from the operating system. So even if CPUID indicates
  207|       |            support for SSE FP, the application might not be able to use it. If
  208|       |            CPUID indicates support for SSE FP, check here whether it is also
  209|       |            supported by the OS, and turn off the SSE FP feature bit if there
  210|       |            is no OS support for SSE FP.
  211|       |
  212|       |            Operating systems that do not support SSE FP return an illegal
  213|       |            instruction exception if execution of an SSE FP instruction is performed.
  214|       |            Here, a sample SSE FP instruction is executed, and is checked for an
  215|       |            exception using the (non-standard) __try/__except mechanism
  216|       |            of Microsoft Visual C/C++.
  217|       |        */
  218|       |        // Visual Studio 2005, Both AMD and Intel x64 support SSE
  219|       |        // note that even though this is a build rather than runtime setting, all
  220|       |        // 64-bit CPUs support this so since binary is 64-bit only we're ok
  221|       |    #if _MSC_VER >= 1400 && defined(_M_X64)
  222|       |            return true;
  223|       |    #else
  224|       |        __try
  225|       |        {
  226|       |            __asm orps  xmm0, xmm0
  227|       |            return true;
  228|       |        }
  229|       |        __except(EXCEPTION_EXECUTE_HANDLER)
  230|       |        {
  231|       |            return false;
  232|       |        }
  233|       |    #endif
  234|       |#elif (OGRE_COMPILER == OGRE_COMPILER_GNUC || OGRE_COMPILER == OGRE_COMPILER_CLANG) && OGRE_PLATFORM != OGRE_PLATFORM_EMSCRIPTEN
  235|       |        #if OGRE_ARCH_TYPE == OGRE_ARCHITECTURE_64 
  236|      2|            return true;
  237|       |        #else
  238|       |        // Does gcc have __try/__except similar mechanism?
  239|       |        // Use signal, setjmp/longjmp instead.
  240|       |        void (*oldHandler)(int);
  241|       |        oldHandler = signal(SIGILL, _illegalHandler);
  242|       |
  243|       |        if (setjmp(sIllegalJmpBuf))
  244|       |        {
  245|       |            signal(SIGILL, oldHandler);
  246|       |            return false;
  247|       |        }
  248|       |        else
  249|       |        {
  250|       |            __asm__ __volatile__ ("orps %xmm0, %xmm0");
  251|       |            signal(SIGILL, oldHandler);
  252|       |            return true;
  253|       |        }
  254|       |       #endif
  255|       |#else
  256|       |        // TODO: Supports other compiler, assumed is supported by default
  257|       |        return true;
  258|       |#endif
  259|      2|    }
OgrePlatformInformation.cpp:_ZN4OgreL15_isSupportCpuidEv:
   83|      4|    {
   84|       |#if OGRE_COMPILER == OGRE_COMPILER_MSVC
   85|       |        // Visual Studio 2005 & 64-bit compilers always supports __cpuid intrinsic
   86|       |        // note that even though this is a build rather than runtime setting, all
   87|       |        // 64-bit CPUs support this so since binary is 64-bit only we're ok
   88|       |    #if _MSC_VER >= 1400 && defined(_M_X64)
   89|       |        return true;
   90|       |    #else
   91|       |        // If we can modify flag register bit 21, the cpu is supports CPUID instruction
   92|       |        __asm
   93|       |        {
   94|       |            // Read EFLAG
   95|       |            pushfd
   96|       |            pop     eax
   97|       |            mov     ecx, eax
   98|       |
   99|       |            // Modify bit 21
  100|       |            xor     eax, 0x200000
  101|       |            push    eax
  102|       |            popfd
  103|       |
  104|       |            // Read back EFLAG
  105|       |            pushfd
  106|       |            pop     eax
  107|       |
  108|       |            // Restore EFLAG
  109|       |            push    ecx
  110|       |            popfd
  111|       |
  112|       |            // Check bit 21 modifiable
  113|       |            xor     eax, ecx
  114|       |            neg     eax
  115|       |            sbb     eax, eax
  116|       |
  117|       |            // Return values in eax, no return statement requirement here for VC.
  118|       |        }
  119|       |    #endif
  120|       |#elif (OGRE_COMPILER == OGRE_COMPILER_GNUC || OGRE_COMPILER == OGRE_COMPILER_CLANG) && OGRE_PLATFORM != OGRE_PLATFORM_EMSCRIPTEN
  121|       |        #if OGRE_ARCH_TYPE == OGRE_ARCHITECTURE_64
  122|      4|           return true;
  123|       |       #else
  124|       |        unsigned oldFlags, newFlags;
  125|       |        __asm__
  126|       |        (
  127|       |            "pushfl         \n\t"
  128|       |            "pop    %0      \n\t"
  129|       |            "mov    %0, %1  \n\t"
  130|       |            "xor    %2, %0  \n\t"
  131|       |            "push   %0      \n\t"
  132|       |            "popfl          \n\t"
  133|       |            "pushfl         \n\t"
  134|       |            "pop    %0      \n\t"
  135|       |            "push   %1      \n\t"
  136|       |            "popfl          \n\t"
  137|       |            : "=r" (oldFlags), "=r" (newFlags)
  138|       |            : "n" (0x200000)
  139|       |        );
  140|       |        return oldFlags != newFlags;
  141|       |       #endif // 64
  142|       |#else
  143|       |        // TODO: Supports other compiler
  144|       |        return false;
  145|       |#endif
  146|      4|    }

_ZN4Ogre20ResourceGroupManagerC2Ev:
   58|      1|        : mLoadingListener(0), mCurrentGroup(0)
   59|      1|    {
   60|       |        // Create the 'General' group
   61|      1|        createResourceGroup(DEFAULT_RESOURCE_GROUP_NAME, true); // the "General" group is synonymous to global pool
   62|       |        // Create the 'Internal' group
   63|      1|        createResourceGroup(INTERNAL_RESOURCE_GROUP_NAME, true);
   64|       |        // Create the 'Autodetect' group (only used for temp storage)
   65|      1|        createResourceGroup(AUTODETECT_RESOURCE_GROUP_NAME, true); // autodetect includes the global pool
   66|       |        // default world group to the default group
   67|      1|        mWorldGroupName = DEFAULT_RESOURCE_GROUP_NAME;
   68|      1|    }
_ZN4Ogre20ResourceGroupManager19createResourceGroupERKNSt3__112basic_stringIcNS1_11char_traitsIcEENS1_9allocatorIcEEEEb:
   83|      3|    {
   84|      3|        LogManager::getSingleton().logMessage("Creating resource group " + name);
   85|      3|        if (getResourceGroup(name))
  ------------------
  |  Branch (85:13): [True: 0, False: 3]
  ------------------
   86|      0|        {
   87|      0|            OGRE_EXCEPT(Exception::ERR_DUPLICATE_ITEM, 
   88|      0|                "Resource group with name '" + name + "' already exists!", 
   89|      0|                "ResourceGroupManager::createResourceGroup");
   90|      0|        }
   91|      3|        ResourceGroup* grp = OGRE_NEW_T(ResourceGroup, MEMCATEGORY_RESOURCE)();
   92|      3|        grp->groupStatus = ResourceGroup::UNINITIALSED;
   93|      3|        grp->name = name;
   94|      3|        grp->inGlobalPool = inGlobalPool;
   95|      3|        grp->customStageCount = 0;
   96|       |
   97|      3|        OGRE_LOCK_AUTO_MUTEX;
   98|      3|        mResourceGroupMap.emplace(name, grp);
   99|      3|    }
_ZNK4Ogre20ResourceGroupManager16getResourceGroupERKNSt3__112basic_stringIcNS1_11char_traitsIcEENS1_9allocatorIcEEEEb:
 1009|      3|    {
 1010|      3|        OGRE_LOCK_AUTO_MUTEX;
 1011|      3|        ResourceGroupMap::const_iterator i = mResourceGroupMap.find(name);
 1012|       |
 1013|      3|        if (i == mResourceGroupMap.end())
  ------------------
  |  Branch (1013:13): [True: 3, False: 0]
  ------------------
 1014|      3|        {
 1015|      3|            if (throwOnFailure)
  ------------------
  |  Branch (1015:17): [True: 0, False: 3]
  ------------------
 1016|      3|                OGRE_EXCEPT(Exception::ERR_ITEM_NOT_FOUND, "Cannot locate a resource group called '" + name + "'");
 1017|       |
 1018|      3|            return nullptr;
 1019|      3|        }
 1020|       |
 1021|      0|        return i->second;
 1022|      3|    }

_ZN4Ogre16StreamSerialiser14makeIdentifierERA5_Kc:
  146|      2|    {
  147|      2|        uint32 ret = 0;
  148|     10|        for (size_t i = 0; i < 4; ++i)
  ------------------
  |  Branch (148:28): [True: 8, False: 2]
  ------------------
  149|      8|        {
  150|      8|            ret += (code[i] << (i * 8));
  151|      8|        }
  152|      2|        return ret;
  153|       |
  154|      2|    }

_ZN4Ogre10StringUtil4trimERNSt3__112basic_stringIcNS1_11char_traitsIcEENS1_9allocatorIcEEEEbb:
   42|      2|    {
   43|       |        /*
   44|       |        size_t lspaces, rspaces, len = length(), i;
   45|       |
   46|       |        lspaces = rspaces = 0;
   47|       |
   48|       |        if( left )
   49|       |        {
   50|       |            // Find spaces / tabs on the left
   51|       |            for( i = 0;
   52|       |                i < len && ( at(i) == ' ' || at(i) == '\t' || at(i) == '\r');
   53|       |                ++lspaces, ++i );
   54|       |        }
   55|       |        
   56|       |        if( right && lspaces < len )
   57|       |        {
   58|       |            // Find spaces / tabs on the right
   59|       |            for( i = len - 1;
   60|       |                i >= 0 && ( at(i) == ' ' || at(i) == '\t' || at(i) == '\r');
   61|       |                rspaces++, i-- );
   62|       |        }
   63|       |
   64|       |        *this = substr(lspaces, len-lspaces-rspaces);
   65|       |        */
   66|      2|        static const String delims = " \t\r\n";
   67|      2|        if(right)
  ------------------
  |  Branch (67:12): [True: 2, False: 0]
  ------------------
   68|      2|            str.erase(str.find_last_not_of(delims)+1); // trim right
   69|      2|        if(left)
  ------------------
  |  Branch (69:12): [True: 2, False: 0]
  ------------------
   70|      2|            str.erase(0, str.find_first_not_of(delims)); // trim left
   71|      2|    }
_ZN4Ogre10StringUtil13splitFilenameERKNSt3__112basic_stringIcNS1_11char_traitsIcEENS1_9allocatorIcEEEERS7_SA_:
  360|  4.42k|    {
  361|  4.42k|        String path = qualifiedName;
  362|       |        // Replace \ with / first
  363|  4.42k|        std::replace( path.begin(), path.end(), '\\', '/' );
  364|       |        // split based on final /
  365|  4.42k|        size_t i = path.find_last_of('/');
  366|       |
  367|  4.42k|        if (i == String::npos)
  ------------------
  |  Branch (367:13): [True: 3.45k, False: 971]
  ------------------
  368|  3.45k|        {
  369|  3.45k|            outPath.clear();
  370|  3.45k|            outBasename = qualifiedName;
  371|  3.45k|        }
  372|    971|        else
  373|    971|        {
  374|    971|            outBasename = path.substr(i+1, path.size() - i - 1);
  375|    971|            outPath = path.substr(0, i+1);
  376|    971|        }
  377|       |
  378|  4.42k|    }

_ZN4Ogre7SamplerC2Ev:
   40|      2|        : mBorderColour(ColourValue::Black)
   41|      2|        , mMaxAniso(1)
   42|      2|        , mMipmapBias(0)
   43|      2|        , mMinFilter(FO_LINEAR)
   44|      2|        , mMagFilter(FO_LINEAR)
   45|      2|        , mMipFilter(FO_POINT)
   46|      2|        , mCompareFunc(CMPF_GREATER_EQUAL)
   47|      2|        , mCompareEnabled(false)
   48|      2|        , mDirty(true)
   49|      2|    {
   50|      2|        setAddressingMode(TAM_WRAP);
   51|      2|    }
_ZN4Ogre7Sampler17setAddressingModeERKNS0_17UVWAddressingModeE:
   55|      2|    {
   56|      2|        mAddressMode = uvw;
   57|      2|        mDirty = true;
   58|      2|    }

_ZN4Ogre25EmbeddedZipArchiveFactoryC2Ev:
  356|      1|    EmbeddedZipArchiveFactory::EmbeddedZipArchiveFactory() {}
_ZN4Ogre25EmbeddedZipArchiveFactory14createInstanceERKNSt3__112basic_stringIcNS1_11char_traitsIcEENS1_9allocatorIcEEEEb:
  360|  3.83k|    {
  361|  3.83k|        auto it = gEmbeddedFileDataList->find(name);
  362|  3.83k|        if(it == gEmbeddedFileDataList->end())
  ------------------
  |  Branch (362:12): [True: 0, False: 3.83k]
  ------------------
  363|      0|            return NULL;
  364|       |
  365|       |        // TODO: decryptFunc
  366|       |
  367|  3.83k|        return new ZipArchive(name, getType(), it->second.fileData, it->second.fileSize);
  368|  3.83k|    }
_ZN4Ogre25EmbeddedZipArchiveFactory15destroyInstanceEPNS_7ArchiveE:
  370|  3.83k|    {
  371|  3.83k|        removeEmbbeddedFile(ptr->getName());
  372|  3.83k|        ZipArchiveFactory::destroyInstance(ptr);
  373|  3.83k|    }
_ZNK4Ogre25EmbeddedZipArchiveFactory7getTypeEv:
  376|  3.83k|    {
  377|  3.83k|        static String name = "EmbeddedZip";
  378|  3.83k|        return name;
  379|  3.83k|    }
_ZN4Ogre25EmbeddedZipArchiveFactory16addEmbbeddedFileERKNSt3__112basic_stringIcNS1_11char_traitsIcEENS1_9allocatorIcEEEEPKhmPFbmPvmE:
  383|  3.83k|    {
  384|  3.83k|        static bool needToInit = true;
  385|  3.83k|        if(needToInit)
  ------------------
  |  Branch (385:12): [True: 1, False: 3.83k]
  ------------------
  386|      1|        {
  387|      1|            needToInit = false;
  388|       |
  389|       |            // we can't be sure when global variables get initialized
  390|       |            // meaning it is possible our list has not been init when this
  391|       |            // function is being called. The solution is to use local
  392|       |            // static members in this function an init the pointers for the
  393|       |            // global here. We know for use that the local static variables
  394|       |            // are create in this stage.
  395|      1|            static EmbbedFileDataList sEmbbedFileDataList;
  396|      1|            gEmbeddedFileDataList = &sEmbbedFileDataList;
  397|      1|        }
  398|       |
  399|  3.83k|        EmbeddedFileData newEmbeddedFileData;
  400|  3.83k|        newEmbeddedFileData.curPos = 0;
  401|  3.83k|        newEmbeddedFileData.isFileOpened = false;
  402|  3.83k|        newEmbeddedFileData.fileData = fileData;
  403|  3.83k|        newEmbeddedFileData.fileSize = fileSize;
  404|  3.83k|        newEmbeddedFileData.decryptFunc = decryptFunc;
  405|  3.83k|        gEmbeddedFileDataList->emplace(name, newEmbeddedFileData);
  406|  3.83k|    }
_ZN4Ogre25EmbeddedZipArchiveFactory19removeEmbbeddedFileERKNSt3__112basic_stringIcNS1_11char_traitsIcEENS1_9allocatorIcEEEE:
  409|  3.83k|    {
  410|  3.83k|        gEmbeddedFileDataList->erase(name);
  411|  3.83k|    }
OgreZip.cpp:_ZN4Ogre12_GLOBAL__N_110ZipArchiveC2ERKNSt3__112basic_stringIcNS2_11char_traitsIcEENS2_9allocatorIcEEEESA_PKhm:
   87|  3.83k|        : Archive(name, archType), mZipFile(0)
   88|  3.83k|    {
   89|  3.83k|        if(externBuf)
  ------------------
  |  Branch (89:12): [True: 3.83k, False: 0]
  ------------------
   90|  3.83k|            mBuffer.reset(new MemoryDataStream(const_cast<uint8*>(externBuf), externBufSz));
   91|  3.83k|    }
OgreZip.cpp:_ZN4Ogre12_GLOBAL__N_110ZipArchiveD2Ev:
   94|  3.83k|    {
   95|  3.83k|        unload();
   96|  3.83k|    }
OgreZip.cpp:_ZN4Ogre12_GLOBAL__N_110ZipArchive4loadEv:
   99|  3.83k|    {
  100|  3.83k|        OGRE_LOCK_AUTO_MUTEX;
  101|  3.83k|        if (!mZipFile)
  ------------------
  |  Branch (101:13): [True: 3.83k, False: 0]
  ------------------
  102|  3.83k|        {
  103|  3.83k|            if(!mBuffer)
  ------------------
  |  Branch (103:16): [True: 0, False: 3.83k]
  ------------------
  104|      0|                mBuffer.reset(new MemoryDataStream(_openFileStream(mName, std::ios::binary)));
  105|       |
  106|  3.83k|            mZipFile = zip_stream_open((const char*)mBuffer->getPtr(), mBuffer->size(), 0, 'r');
  107|       |
  108|       |            // Cache names
  109|  3.83k|            int n = zip_entries_total(mZipFile);
  110|  7.73k|            for (int i = 0; i < n; ++i) {
  ------------------
  |  Branch (110:29): [True: 3.90k, False: 3.83k]
  ------------------
  111|  3.90k|                FileInfo info;
  112|  3.90k|                info.archive = this;
  113|       |
  114|  3.90k|                zip_entry_openbyindex(mZipFile, i);
  115|       |
  116|  3.90k|                info.filename = zip_entry_name(mZipFile);
  117|       |                // Get basename / path
  118|  3.90k|                StringUtil::splitFilename(info.filename, info.basename, info.path);
  119|       |
  120|       |                // Get sizes
  121|  3.90k|                info.uncompressedSize = zip_entry_size(mZipFile);
  122|  3.90k|                info.compressedSize = zip_entry_comp_size(mZipFile);
  123|       |
  124|  3.90k|                if (zip_entry_isdir(mZipFile))
  ------------------
  |  Branch (124:21): [True: 520, False: 3.38k]
  ------------------
  125|    520|                {
  126|    520|                    info.filename = info.filename.substr(0, info.filename.length() - 1);
  127|    520|                    StringUtil::splitFilename(info.filename, info.basename, info.path);
  128|       |                    // Set compressed size to -1 for folders; anyway nobody will check
  129|       |                    // the compressed size of a folder, and if he does, its useless anyway
  130|    520|                    info.compressedSize = size_t(-1);
  131|    520|                }
  132|       |#if !OGRE_RESOURCEMANAGER_STRICT
  133|       |                else
  134|       |                {
  135|       |                    info.filename = info.basename;
  136|       |                }
  137|       |#endif
  138|  3.90k|                zip_entry_close(mZipFile);
  139|  3.90k|                mFileList.push_back(info);
  140|  3.90k|            }
  141|  3.83k|        }
  142|  3.83k|    }
OgreZip.cpp:_ZN4Ogre12_GLOBAL__N_110ZipArchive6unloadEv:
  145|  7.66k|    {
  146|  7.66k|        OGRE_LOCK_AUTO_MUTEX;
  147|  7.66k|        if (mZipFile)
  ------------------
  |  Branch (147:13): [True: 2.55k, False: 5.10k]
  ------------------
  148|  2.55k|        {
  149|  2.55k|            zip_close(mZipFile);
  150|  2.55k|            mZipFile = 0;
  151|  2.55k|            mFileList.clear();
  152|  2.55k|            mBuffer.reset();
  153|  2.55k|        }
  154|       |    
  155|  7.66k|    }
OgreZip.cpp:_ZNK4Ogre12_GLOBAL__N_110ZipArchive4openERKNSt3__112basic_stringIcNS2_11char_traitsIcEENS2_9allocatorIcEEEEb:
  158|  3.38k|    {
  159|       |        // zip is not threadsafe
  160|  3.38k|        OGRE_LOCK_AUTO_MUTEX;
  161|  3.38k|        String lookUpFileName = filename;
  162|       |
  163|  3.38k|#if OGRE_RESOURCEMANAGER_STRICT
  164|  3.38k|        bool open = zip_entry_opencasesensitive(mZipFile, lookUpFileName.c_str()) == 0;
  165|       |#else
  166|       |        bool open = zip_entry_open(mZipFile, lookUpFileName.c_str()) == 0;
  167|       |        if (!open) // Try if we find the file
  168|       |        {
  169|       |            String basename, path;
  170|       |            StringUtil::splitFilename(lookUpFileName, basename, path);
  171|       |            const FileInfoListPtr fileNfo = findFileInfo(basename, true);
  172|       |            if (fileNfo->size() == 1) // If there are more files with the same do not open anyone
  173|       |            {
  174|       |                Ogre::FileInfo info = fileNfo->at(0);
  175|       |                lookUpFileName = info.path + info.basename;
  176|       |                open = zip_entry_open(mZipFile, lookUpFileName.c_str(), OGRE_RESOURCEMANAGER_STRICT) == 0;
  177|       |            }
  178|       |        }
  179|       |#endif
  180|       |
  181|  3.38k|        if (!open)
  ------------------
  |  Branch (181:13): [True: 883, False: 2.50k]
  ------------------
  182|    883|        {
  183|    883|            OGRE_EXCEPT(Exception::ERR_FILE_NOT_FOUND, "could not open "+lookUpFileName);
  184|    883|        }
  185|       |
  186|       |        // Construct & return stream
  187|  2.50k|        size_t entrySize = zip_entry_size(mZipFile);
  188|  2.50k|        size_t compSize  = zip_entry_comp_size(mZipFile);
  189|       |        // repetitive log files have a typical ratio of ~50:1, XML 30:1, images 5:1
  190|  2.50k|        const size_t MAX_RATIO = 100;
  191|  2.50k|        if (entrySize > 0 && (compSize == 0 || entrySize / compSize > MAX_RATIO))
  ------------------
  |  Branch (191:13): [True: 2.36k, False: 137]
  |  Branch (191:31): [True: 6, False: 2.35k]
  |  Branch (191:48): [True: 924, False: 1.43k]
  ------------------
  192|    930|        {
  193|    930|            zip_entry_close(mZipFile);
  194|    930|            OGRE_EXCEPT(Exception::ERR_INVALIDPARAMS,
  195|    930|                        "zip entry has suspicious compression ratio (possible decompression bomb): " + lookUpFileName);
  196|    930|        }
  197|  1.57k|        auto ret = std::make_shared<MemoryDataStream>(lookUpFileName, entrySize, true, true);
  198|       |
  199|  1.57k|        if(zip_entry_noallocread(mZipFile, ret->getPtr(), ret->size()) < 0)
  ------------------
  |  Branch (199:12): [True: 1.20k, False: 369]
  ------------------
  200|  1.20k|        {
  201|  1.20k|            zip_entry_close(mZipFile);
  202|  1.20k|            OGRE_EXCEPT(Exception::ERR_FILE_NOT_FOUND, "could not read "+lookUpFileName);
  203|  1.20k|        }
  204|    369|        zip_entry_close(mZipFile);
  205|       |
  206|    369|        return ret;
  207|  1.57k|    }
OgreZip.cpp:_ZNK4Ogre12_GLOBAL__N_110ZipArchive4listEbb:
  220|  3.83k|    {
  221|  3.83k|        OGRE_LOCK_AUTO_MUTEX;
  222|  3.83k|        auto ret = std::make_shared<StringVector>();
  223|       |
  224|  3.83k|        for (auto& f : mFileList)
  ------------------
  |  Branch (224:22): [True: 3.90k, False: 3.83k]
  ------------------
  225|  3.90k|            if ((dirs == (f.compressedSize == size_t (-1))) &&
  ------------------
  |  Branch (225:17): [True: 3.38k, False: 522]
  ------------------
  226|  3.38k|                (recursive || f.path.empty()))
  ------------------
  |  Branch (226:18): [True: 3.38k, False: 0]
  |  Branch (226:31): [True: 0, False: 0]
  ------------------
  227|  3.38k|                ret->push_back(f.filename);
  228|       |
  229|  3.83k|        return ret;
  230|  3.83k|    }

mz_crc32:
 1988|    149|mz_ulong mz_crc32(mz_ulong crc, const mz_uint8 *ptr, size_t buf_len) {
 1989|    149|  static const mz_uint32 s_crc_table[256] = {
 1990|    149|      0x00000000, 0x77073096, 0xEE0E612C, 0x990951BA, 0x076DC419, 0x706AF48F,
 1991|    149|      0xE963A535, 0x9E6495A3, 0x0EDB8832, 0x79DCB8A4, 0xE0D5E91E, 0x97D2D988,
 1992|    149|      0x09B64C2B, 0x7EB17CBD, 0xE7B82D07, 0x90BF1D91, 0x1DB71064, 0x6AB020F2,
 1993|    149|      0xF3B97148, 0x84BE41DE, 0x1ADAD47D, 0x6DDDE4EB, 0xF4D4B551, 0x83D385C7,
 1994|    149|      0x136C9856, 0x646BA8C0, 0xFD62F97A, 0x8A65C9EC, 0x14015C4F, 0x63066CD9,
 1995|    149|      0xFA0F3D63, 0x8D080DF5, 0x3B6E20C8, 0x4C69105E, 0xD56041E4, 0xA2677172,
 1996|    149|      0x3C03E4D1, 0x4B04D447, 0xD20D85FD, 0xA50AB56B, 0x35B5A8FA, 0x42B2986C,
 1997|    149|      0xDBBBC9D6, 0xACBCF940, 0x32D86CE3, 0x45DF5C75, 0xDCD60DCF, 0xABD13D59,
 1998|    149|      0x26D930AC, 0x51DE003A, 0xC8D75180, 0xBFD06116, 0x21B4F4B5, 0x56B3C423,
 1999|    149|      0xCFBA9599, 0xB8BDA50F, 0x2802B89E, 0x5F058808, 0xC60CD9B2, 0xB10BE924,
 2000|    149|      0x2F6F7C87, 0x58684C11, 0xC1611DAB, 0xB6662D3D, 0x76DC4190, 0x01DB7106,
 2001|    149|      0x98D220BC, 0xEFD5102A, 0x71B18589, 0x06B6B51F, 0x9FBFE4A5, 0xE8B8D433,
 2002|    149|      0x7807C9A2, 0x0F00F934, 0x9609A88E, 0xE10E9818, 0x7F6A0DBB, 0x086D3D2D,
 2003|    149|      0x91646C97, 0xE6635C01, 0x6B6B51F4, 0x1C6C6162, 0x856530D8, 0xF262004E,
 2004|    149|      0x6C0695ED, 0x1B01A57B, 0x8208F4C1, 0xF50FC457, 0x65B0D9C6, 0x12B7E950,
 2005|    149|      0x8BBEB8EA, 0xFCB9887C, 0x62DD1DDF, 0x15DA2D49, 0x8CD37CF3, 0xFBD44C65,
 2006|    149|      0x4DB26158, 0x3AB551CE, 0xA3BC0074, 0xD4BB30E2, 0x4ADFA541, 0x3DD895D7,
 2007|    149|      0xA4D1C46D, 0xD3D6F4FB, 0x4369E96A, 0x346ED9FC, 0xAD678846, 0xDA60B8D0,
 2008|    149|      0x44042D73, 0x33031DE5, 0xAA0A4C5F, 0xDD0D7CC9, 0x5005713C, 0x270241AA,
 2009|    149|      0xBE0B1010, 0xC90C2086, 0x5768B525, 0x206F85B3, 0xB966D409, 0xCE61E49F,
 2010|    149|      0x5EDEF90E, 0x29D9C998, 0xB0D09822, 0xC7D7A8B4, 0x59B33D17, 0x2EB40D81,
 2011|    149|      0xB7BD5C3B, 0xC0BA6CAD, 0xEDB88320, 0x9ABFB3B6, 0x03B6E20C, 0x74B1D29A,
 2012|    149|      0xEAD54739, 0x9DD277AF, 0x04DB2615, 0x73DC1683, 0xE3630B12, 0x94643B84,
 2013|    149|      0x0D6D6A3E, 0x7A6A5AA8, 0xE40ECF0B, 0x9309FF9D, 0x0A00AE27, 0x7D079EB1,
 2014|    149|      0xF00F9344, 0x8708A3D2, 0x1E01F268, 0x6906C2FE, 0xF762575D, 0x806567CB,
 2015|    149|      0x196C3671, 0x6E6B06E7, 0xFED41B76, 0x89D32BE0, 0x10DA7A5A, 0x67DD4ACC,
 2016|    149|      0xF9B9DF6F, 0x8EBEEFF9, 0x17B7BE43, 0x60B08ED5, 0xD6D6A3E8, 0xA1D1937E,
 2017|    149|      0x38D8C2C4, 0x4FDFF252, 0xD1BB67F1, 0xA6BC5767, 0x3FB506DD, 0x48B2364B,
 2018|    149|      0xD80D2BDA, 0xAF0A1B4C, 0x36034AF6, 0x41047A60, 0xDF60EFC3, 0xA867DF55,
 2019|    149|      0x316E8EEF, 0x4669BE79, 0xCB61B38C, 0xBC66831A, 0x256FD2A0, 0x5268E236,
 2020|    149|      0xCC0C7795, 0xBB0B4703, 0x220216B9, 0x5505262F, 0xC5BA3BBE, 0xB2BD0B28,
 2021|    149|      0x2BB45A92, 0x5CB36A04, 0xC2D7FFA7, 0xB5D0CF31, 0x2CD99E8B, 0x5BDEAE1D,
 2022|    149|      0x9B64C2B0, 0xEC63F226, 0x756AA39C, 0x026D930A, 0x9C0906A9, 0xEB0E363F,
 2023|    149|      0x72076785, 0x05005713, 0x95BF4A82, 0xE2B87A14, 0x7BB12BAE, 0x0CB61B38,
 2024|    149|      0x92D28E9B, 0xE5D5BE0D, 0x7CDCEFB7, 0x0BDBDF21, 0x86D3D2D4, 0xF1D4E242,
 2025|    149|      0x68DDB3F8, 0x1FDA836E, 0x81BE16CD, 0xF6B9265B, 0x6FB077E1, 0x18B74777,
 2026|    149|      0x88085AE6, 0xFF0F6A70, 0x66063BCA, 0x11010B5C, 0x8F659EFF, 0xF862AE69,
 2027|    149|      0x616BFFD3, 0x166CCF45, 0xA00AE278, 0xD70DD2EE, 0x4E048354, 0x3903B3C2,
 2028|    149|      0xA7672661, 0xD06016F7, 0x4969474D, 0x3E6E77DB, 0xAED16A4A, 0xD9D65ADC,
 2029|    149|      0x40DF0B66, 0x37D83BF0, 0xA9BCAE53, 0xDEBB9EC5, 0x47B2CF7F, 0x30B5FFE9,
 2030|    149|      0xBDBDF21C, 0xCABAC28A, 0x53B39330, 0x24B4A3A6, 0xBAD03605, 0xCDD70693,
 2031|    149|      0x54DE5729, 0x23D967BF, 0xB3667A2E, 0xC4614AB8, 0x5D681B02, 0x2A6F2B94,
 2032|    149|      0xB40BBE37, 0xC30C8EA1, 0x5A05DF1B, 0x2D02EF8D};
 2033|       |
 2034|    149|  mz_uint32 crc32 = (mz_uint32)crc ^ 0xFFFFFFFF;
 2035|    149|  const mz_uint8 *pByte_buf = (const mz_uint8 *)ptr;
 2036|       |
 2037|  67.9k|  while (buf_len >= 4) {
  ------------------
  |  Branch (2037:10): [True: 67.7k, False: 149]
  ------------------
 2038|  67.7k|    crc32 = (crc32 >> 8) ^ s_crc_table[(crc32 ^ pByte_buf[0]) & 0xFF];
 2039|  67.7k|    crc32 = (crc32 >> 8) ^ s_crc_table[(crc32 ^ pByte_buf[1]) & 0xFF];
 2040|  67.7k|    crc32 = (crc32 >> 8) ^ s_crc_table[(crc32 ^ pByte_buf[2]) & 0xFF];
 2041|  67.7k|    crc32 = (crc32 >> 8) ^ s_crc_table[(crc32 ^ pByte_buf[3]) & 0xFF];
 2042|  67.7k|    pByte_buf += 4;
 2043|  67.7k|    buf_len -= 4;
 2044|  67.7k|  }
 2045|       |
 2046|    252|  while (buf_len) {
  ------------------
  |  Branch (2046:10): [True: 103, False: 149]
  ------------------
 2047|    103|    crc32 = (crc32 >> 8) ^ s_crc_table[(crc32 ^ pByte_buf[0]) & 0xFF];
 2048|    103|    ++pByte_buf;
 2049|    103|    --buf_len;
 2050|    103|  }
 2051|       |
 2052|    149|  return ~crc32;
 2053|    149|}
miniz_def_alloc_func:
 2059|  3.82k|                                        size_t size) {
 2060|  3.82k|  (void)opaque, (void)items, (void)size;
 2061|  3.82k|  return MZ_MALLOC(items * size);
  ------------------
  |  |  753|  3.82k|#define MZ_MALLOC(x) malloc(x)
  ------------------
 2062|  3.82k|}
miniz_def_free_func:
 2063|  15.2k|MINIZ_EXPORT void miniz_def_free_func(void *opaque, void *address) {
 2064|  15.2k|  (void)opaque, (void)address;
 2065|  15.2k|  MZ_FREE(address);
  ------------------
  |  |  754|  15.2k|#define MZ_FREE(x) free(x)
  ------------------
 2066|  15.2k|}
miniz_def_realloc_func:
 2068|  8.91k|                                          size_t items, size_t size) {
 2069|  8.91k|  (void)opaque, (void)address, (void)items, (void)size;
 2070|  8.91k|  return MZ_REALLOC(address, items * size);
  ------------------
  |  |  755|  8.91k|#define MZ_REALLOC(p, x) realloc(p, x)
  ------------------
 2071|  8.91k|}
tinfl_decompress:
 4388|    468|                              const mz_uint32 decomp_flags) {
 4389|    468|  static const mz_uint16 s_length_base[31] = {
 4390|    468|      3,  4,  5,  6,  7,  8,  9,  10,  11,  13,  15,  17,  19,  23, 27, 31,
 4391|    468|      35, 43, 51, 59, 67, 83, 99, 115, 131, 163, 195, 227, 258, 0,  0};
 4392|    468|  static const mz_uint8 s_length_extra[31] = {0, 0, 0, 0, 0, 0, 0, 0, 1, 1, 1,
 4393|    468|                                              1, 2, 2, 2, 2, 3, 3, 3, 3, 4, 4,
 4394|    468|                                              4, 4, 5, 5, 5, 5, 0, 0, 0};
 4395|    468|  static const mz_uint16 s_dist_base[32] = {
 4396|    468|      1,    2,    3,    4,    5,    7,     9,     13,    17,  25,   33,
 4397|    468|      49,   65,   97,   129,  193,  257,   385,   513,   769, 1025, 1537,
 4398|    468|      2049, 3073, 4097, 6145, 8193, 12289, 16385, 24577, 0,   0};
 4399|    468|  static const mz_uint8 s_dist_extra[32] = {
 4400|    468|      0, 0, 0, 0, 1, 1, 2, 2,  3,  3,  4,  4,  5,  5,  6,
 4401|    468|      6, 7, 7, 8, 8, 9, 9, 10, 10, 11, 11, 12, 12, 13, 13};
 4402|    468|  static const mz_uint8 s_length_dezigzag[19] = {
 4403|    468|      16, 17, 18, 0, 8, 7, 9, 6, 10, 5, 11, 4, 12, 3, 13, 2, 14, 1, 15};
 4404|    468|  static const mz_uint16 s_min_table_sizes[3] = {257, 1, 4};
 4405|       |
 4406|    468|  mz_int16 *pTrees[3];
 4407|    468|  mz_uint8 *pCode_sizes[3];
 4408|       |
 4409|    468|  tinfl_status status = TINFL_STATUS_FAILED;
 4410|    468|  mz_uint32 num_bits, dist, counter, num_extra;
 4411|    468|  tinfl_bit_buf_t bit_buf;
 4412|    468|  const mz_uint8 *pIn_buf_cur = pIn_buf_next, *const pIn_buf_end =
 4413|    468|                                                  pIn_buf_next + *pIn_buf_size;
 4414|    468|  mz_uint8 *pOut_buf_cur = pOut_buf_next, *const pOut_buf_end =
 4415|    468|                                              pOut_buf_next ? pOut_buf_next +
  ------------------
  |  Branch (4415:47): [True: 468, False: 0]
  ------------------
 4416|    468|                                                                  *pOut_buf_size
 4417|    468|                                                            : NULL;
 4418|    468|  size_t out_buf_size_mask =
 4419|    468|             (decomp_flags & TINFL_FLAG_USING_NON_WRAPPING_OUTPUT_BUF)
  ------------------
  |  Branch (4419:14): [True: 468, False: 0]
  ------------------
 4420|    468|                 ? (size_t)-1
 4421|    468|                 : ((pOut_buf_next - pOut_buf_start) + *pOut_buf_size) - 1,
 4422|    468|         dist_from_out_buf_start;
 4423|       |
 4424|       |  /* Ensure the output buffer's size is a power of 2, unless the output buffer
 4425|       |   * is large enough to hold the entire output file (in which case it doesn't
 4426|       |   * matter). */
 4427|    468|  if (((out_buf_size_mask + 1) & out_buf_size_mask) ||
  ------------------
  |  Branch (4427:7): [True: 0, False: 468]
  ------------------
 4428|    468|      (pOut_buf_next < pOut_buf_start)) {
  ------------------
  |  Branch (4428:7): [True: 0, False: 468]
  ------------------
 4429|      0|    *pIn_buf_size = *pOut_buf_size = 0;
 4430|      0|    return TINFL_STATUS_BAD_PARAM;
 4431|      0|  }
 4432|       |
 4433|    468|  pTrees[0] = r->m_tree_0;
 4434|    468|  pTrees[1] = r->m_tree_1;
 4435|    468|  pTrees[2] = r->m_tree_2;
 4436|    468|  pCode_sizes[0] = r->m_code_size_0;
 4437|    468|  pCode_sizes[1] = r->m_code_size_1;
 4438|    468|  pCode_sizes[2] = r->m_code_size_2;
 4439|       |
 4440|    468|  num_bits = r->m_num_bits;
 4441|    468|  bit_buf = r->m_bit_buf;
 4442|    468|  dist = r->m_dist;
 4443|    468|  counter = r->m_counter;
 4444|    468|  num_extra = r->m_num_extra;
 4445|    468|  dist_from_out_buf_start = r->m_dist_from_out_buf_start;
 4446|    468|  TINFL_CR_BEGIN
  ------------------
  |  | 4245|    936|  switch (r->m_state) {                                                        \
  |  |  ------------------
  |  |  |  Branch (4245:11): [True: 468, False: 0]
  |  |  ------------------
  |  | 4246|    468|  case 0:
  |  |  ------------------
  |  |  |  Branch (4246:3): [True: 468, False: 0]
  |  |  ------------------
  ------------------
 4447|       |
 4448|    468|  bit_buf = num_bits = dist = counter = num_extra = r->m_zhdr0 = r->m_zhdr1 = 0;
 4449|    468|  r->m_z_adler32 = r->m_check_adler32 = 1;
 4450|    468|  if (decomp_flags & TINFL_FLAG_PARSE_ZLIB_HEADER) {
  ------------------
  |  Branch (4450:7): [True: 0, False: 468]
  ------------------
 4451|      0|    TINFL_GET_BYTE(1, r->m_zhdr0);
  ------------------
  |  | 4265|      0|  do {                                                                         \
  |  | 4266|      0|    while (pIn_buf_cur >= pIn_buf_end) {                                       \
  |  |  ------------------
  |  |  |  Branch (4266:12): [True: 0, False: 0]
  |  |  ------------------
  |  | 4267|      0|      TINFL_CR_RETURN(state_index,                                             \
  |  |  ------------------
  |  |  |  | 4248|      0|  do {                                                                         \
  |  |  |  | 4249|      0|    status = result;                                                           \
  |  |  |  |  ------------------
  |  |  |  |  |  Branch (4249:14): [True: 0, False: 0]
  |  |  |  |  ------------------
  |  |  |  | 4250|      0|    r->m_state = state_index;                                                  \
  |  |  |  | 4251|      0|    goto common_exit;                                                          \
  |  |  |  | 4252|      0|  case state_index:;                                                           \
  |  |  |  |  ------------------
  |  |  |  |  |  Branch (4252:3): [True: 0, False: 468]
  |  |  |  |  ------------------
  |  |  |  | 4253|      0|  }                                                                            \
  |  |  |  | 4254|      0|  MZ_MACRO_END
  |  |  |  |  ------------------
  |  |  |  |  |  |  726|      0|#define MZ_MACRO_END while (0)
  |  |  |  |  |  |  ------------------
  |  |  |  |  |  |  |  Branch (726:29): [Folded, False: 0]
  |  |  |  |  |  |  ------------------
  |  |  |  |  ------------------
  |  |  ------------------
  |  | 4268|      0|                      (decomp_flags & TINFL_FLAG_HAS_MORE_INPUT)               \
  |  | 4269|      0|                          ? TINFL_STATUS_NEEDS_MORE_INPUT                      \
  |  | 4270|      0|                          : TINFL_STATUS_FAILED_CANNOT_MAKE_PROGRESS);         \
  |  | 4271|      0|    }                                                                          \
  |  | 4272|      0|    c = *pIn_buf_cur++;                                                        \
  |  | 4273|      0|  }                                                                            \
  |  | 4274|      0|  MZ_MACRO_END
  |  |  ------------------
  |  |  |  |  726|      0|#define MZ_MACRO_END while (0)
  |  |  |  |  ------------------
  |  |  |  |  |  Branch (726:29): [Folded, False: 0]
  |  |  |  |  ------------------
  |  |  ------------------
  ------------------
 4452|      0|    TINFL_GET_BYTE(2, r->m_zhdr1);
  ------------------
  |  | 4265|      0|  do {                                                                         \
  |  | 4266|      0|    while (pIn_buf_cur >= pIn_buf_end) {                                       \
  |  |  ------------------
  |  |  |  Branch (4266:12): [True: 0, False: 0]
  |  |  ------------------
  |  | 4267|      0|      TINFL_CR_RETURN(state_index,                                             \
  |  |  ------------------
  |  |  |  | 4248|      0|  do {                                                                         \
  |  |  |  | 4249|      0|    status = result;                                                           \
  |  |  |  |  ------------------
  |  |  |  |  |  Branch (4249:14): [True: 0, False: 0]
  |  |  |  |  ------------------
  |  |  |  | 4250|      0|    r->m_state = state_index;                                                  \
  |  |  |  | 4251|      0|    goto common_exit;                                                          \
  |  |  |  | 4252|      0|  case state_index:;                                                           \
  |  |  |  |  ------------------
  |  |  |  |  |  Branch (4252:3): [True: 0, False: 468]
  |  |  |  |  ------------------
  |  |  |  | 4253|      0|  }                                                                            \
  |  |  |  | 4254|      0|  MZ_MACRO_END
  |  |  |  |  ------------------
  |  |  |  |  |  |  726|      0|#define MZ_MACRO_END while (0)
  |  |  |  |  |  |  ------------------
  |  |  |  |  |  |  |  Branch (726:29): [Folded, False: 0]
  |  |  |  |  |  |  ------------------
  |  |  |  |  ------------------
  |  |  ------------------
  |  | 4268|      0|                      (decomp_flags & TINFL_FLAG_HAS_MORE_INPUT)               \
  |  | 4269|      0|                          ? TINFL_STATUS_NEEDS_MORE_INPUT                      \
  |  | 4270|      0|                          : TINFL_STATUS_FAILED_CANNOT_MAKE_PROGRESS);         \
  |  | 4271|      0|    }                                                                          \
  |  | 4272|      0|    c = *pIn_buf_cur++;                                                        \
  |  | 4273|      0|  }                                                                            \
  |  | 4274|      0|  MZ_MACRO_END
  |  |  ------------------
  |  |  |  |  726|      0|#define MZ_MACRO_END while (0)
  |  |  |  |  ------------------
  |  |  |  |  |  Branch (726:29): [Folded, False: 0]
  |  |  |  |  ------------------
  |  |  ------------------
  ------------------
 4453|      0|    counter = (((r->m_zhdr0 * 256 + r->m_zhdr1) % 31 != 0) ||
  ------------------
  |  Branch (4453:16): [True: 0, False: 0]
  ------------------
 4454|      0|               (r->m_zhdr1 & 32) || ((r->m_zhdr0 & 15) != 8));
  ------------------
  |  Branch (4454:16): [True: 0, False: 0]
  |  Branch (4454:37): [True: 0, False: 0]
  ------------------
 4455|      0|    if (!(decomp_flags & TINFL_FLAG_USING_NON_WRAPPING_OUTPUT_BUF))
  ------------------
  |  Branch (4455:9): [True: 0, False: 0]
  ------------------
 4456|      0|      counter |= (((1U << (8U + (r->m_zhdr0 >> 4))) > 32768U) ||
  ------------------
  |  Branch (4456:19): [True: 0, False: 0]
  ------------------
 4457|      0|                  ((out_buf_size_mask + 1) <
  ------------------
  |  Branch (4457:19): [True: 0, False: 0]
  ------------------
 4458|      0|                   (size_t)((size_t)1 << (8U + (r->m_zhdr0 >> 4)))));
 4459|      0|    if (counter) {
  ------------------
  |  Branch (4459:9): [True: 0, False: 0]
  ------------------
 4460|      0|      TINFL_CR_RETURN_FOREVER(36, TINFL_STATUS_FAILED);
  ------------------
  |  | 4256|      0|  do {                                                                         \
  |  | 4257|      0|    for (;;) {                                                                 \
  |  | 4258|      0|      TINFL_CR_RETURN(state_index, result);                                    \
  |  |  ------------------
  |  |  |  | 4248|      0|  do {                                                                         \
  |  |  |  | 4249|      0|    status = result;                                                           \
  |  |  |  | 4250|      0|    r->m_state = state_index;                                                  \
  |  |  |  | 4251|      0|    goto common_exit;                                                          \
  |  |  |  | 4252|      0|  case state_index:;                                                           \
  |  |  |  |  ------------------
  |  |  |  |  |  Branch (4252:3): [True: 0, False: 468]
  |  |  |  |  ------------------
  |  |  |  | 4253|      0|  }                                                                            \
  |  |  |  | 4254|      0|  MZ_MACRO_END
  |  |  |  |  ------------------
  |  |  |  |  |  |  726|      0|#define MZ_MACRO_END while (0)
  |  |  |  |  |  |  ------------------
  |  |  |  |  |  |  |  Branch (726:29): [Folded, False: 0]
  |  |  |  |  |  |  ------------------
  |  |  |  |  ------------------
  |  |  ------------------
  |  | 4259|      0|    }                                                                          \
  |  | 4260|      0|  }                                                                            \
  |  | 4261|      0|  MZ_MACRO_END
  |  |  ------------------
  |  |  |  |  726|      0|#define MZ_MACRO_END while (0)
  |  |  |  |  ------------------
  |  |  |  |  |  Branch (726:29): [Folded, False: 0]
  |  |  |  |  ------------------
  |  |  ------------------
  ------------------
 4461|      0|    }
 4462|      0|  }
 4463|       |
 4464|  1.73k|  do {
 4465|  1.73k|    TINFL_GET_BITS(3, r->m_final, 3);
  ------------------
  |  | 4293|  1.73k|  do {                                                                         \
  |  | 4294|  1.73k|    if (num_bits < (mz_uint)(n)) {                                             \
  |  |  ------------------
  |  |  |  Branch (4294:9): [True: 650, False: 1.08k]
  |  |  ------------------
  |  | 4295|    650|      TINFL_NEED_BITS(state_index, n);                                         \
  |  |  ------------------
  |  |  |  | 4277|    650|  do {                                                                         \
  |  |  |  | 4278|    650|    mz_uint c;                                                                 \
  |  |  |  | 4279|    650|    TINFL_GET_BYTE(state_index, c);                                            \
  |  |  |  |  ------------------
  |  |  |  |  |  | 4265|    650|  do {                                                                         \
  |  |  |  |  |  | 4266|    650|    while (pIn_buf_cur >= pIn_buf_end) {                                       \
  |  |  |  |  |  |  ------------------
  |  |  |  |  |  |  |  Branch (4266:12): [True: 26, False: 624]
  |  |  |  |  |  |  ------------------
  |  |  |  |  |  | 4267|     26|      TINFL_CR_RETURN(state_index,                                             \
  |  |  |  |  |  |  ------------------
  |  |  |  |  |  |  |  | 4248|     26|  do {                                                                         \
  |  |  |  |  |  |  |  | 4249|     52|    status = result;                                                           \
  |  |  |  |  |  |  |  |  ------------------
  |  |  |  |  |  |  |  |  |  Branch (4249:14): [True: 0, False: 26]
  |  |  |  |  |  |  |  |  ------------------
  |  |  |  |  |  |  |  | 4250|     26|    r->m_state = state_index;                                                  \
  |  |  |  |  |  |  |  | 4251|     26|    goto common_exit;                                                          \
  |  |  |  |  |  |  |  | 4252|     26|  case state_index:;                                                           \
  |  |  |  |  |  |  |  |  ------------------
  |  |  |  |  |  |  |  |  |  Branch (4252:3): [True: 0, False: 468]
  |  |  |  |  |  |  |  |  ------------------
  |  |  |  |  |  |  |  | 4253|      0|  }                                                                            \
  |  |  |  |  |  |  |  | 4254|     26|  MZ_MACRO_END
  |  |  |  |  |  |  |  |  ------------------
  |  |  |  |  |  |  |  |  |  |  726|     26|#define MZ_MACRO_END while (0)
  |  |  |  |  |  |  |  |  |  |  ------------------
  |  |  |  |  |  |  |  |  |  |  |  Branch (726:29): [Folded, False: 0]
  |  |  |  |  |  |  |  |  |  |  ------------------
  |  |  |  |  |  |  |  |  ------------------
  |  |  |  |  |  |  ------------------
  |  |  |  |  |  | 4268|     26|                      (decomp_flags & TINFL_FLAG_HAS_MORE_INPUT)               \
  |  |  |  |  |  | 4269|     26|                          ? TINFL_STATUS_NEEDS_MORE_INPUT                      \
  |  |  |  |  |  | 4270|     26|                          : TINFL_STATUS_FAILED_CANNOT_MAKE_PROGRESS);         \
  |  |  |  |  |  | 4271|     26|    }                                                                          \
  |  |  |  |  |  | 4272|    650|    c = *pIn_buf_cur++;                                                        \
  |  |  |  |  |  | 4273|    624|  }                                                                            \
  |  |  |  |  |  | 4274|    650|  MZ_MACRO_END
  |  |  |  |  |  |  ------------------
  |  |  |  |  |  |  |  |  726|    650|#define MZ_MACRO_END while (0)
  |  |  |  |  |  |  |  |  ------------------
  |  |  |  |  |  |  |  |  |  Branch (726:29): [Folded, False: 624]
  |  |  |  |  |  |  |  |  ------------------
  |  |  |  |  |  |  ------------------
  |  |  |  |  ------------------
  |  |  |  | 4280|    650|    bit_buf |= (((tinfl_bit_buf_t)c) << num_bits);                             \
  |  |  |  | 4281|    624|    num_bits += 8;                                                             \
  |  |  |  | 4282|    624|  } while (num_bits < (mz_uint)(n))
  |  |  |  |  ------------------
  |  |  |  |  |  Branch (4282:12): [True: 0, False: 624]
  |  |  |  |  ------------------
  |  |  ------------------
  |  | 4296|    650|    }                                                                          \
  |  | 4297|  1.73k|    b = bit_buf & ((1 << (n)) - 1);                                            \
  |  | 4298|  1.70k|    bit_buf >>= (n);                                                           \
  |  | 4299|  1.70k|    num_bits -= (n);                                                           \
  |  | 4300|  1.70k|  }                                                                            \
  |  | 4301|  1.73k|  MZ_MACRO_END
  |  |  ------------------
  |  |  |  |  726|  1.73k|#define MZ_MACRO_END while (0)
  |  |  |  |  ------------------
  |  |  |  |  |  Branch (726:29): [Folded, False: 1.70k]
  |  |  |  |  ------------------
  |  |  ------------------
  ------------------
 4466|  1.70k|    r->m_type = r->m_final >> 1;
 4467|  1.70k|    if (r->m_type == 0) {
  ------------------
  |  Branch (4467:9): [True: 264, False: 1.44k]
  ------------------
 4468|    264|      TINFL_SKIP_BITS(5, num_bits & 7);
  ------------------
  |  | 4284|    264|  do {                                                                         \
  |  | 4285|    264|    if (num_bits < (mz_uint)(n)) {                                             \
  |  |  ------------------
  |  |  |  Branch (4285:9): [True: 0, False: 264]
  |  |  ------------------
  |  | 4286|      0|      TINFL_NEED_BITS(state_index, n);                                         \
  |  |  ------------------
  |  |  |  | 4277|      0|  do {                                                                         \
  |  |  |  | 4278|      0|    mz_uint c;                                                                 \
  |  |  |  | 4279|      0|    TINFL_GET_BYTE(state_index, c);                                            \
  |  |  |  |  ------------------
  |  |  |  |  |  | 4265|      0|  do {                                                                         \
  |  |  |  |  |  | 4266|      0|    while (pIn_buf_cur >= pIn_buf_end) {                                       \
  |  |  |  |  |  |  ------------------
  |  |  |  |  |  |  |  Branch (4266:12): [True: 0, False: 0]
  |  |  |  |  |  |  ------------------
  |  |  |  |  |  | 4267|      0|      TINFL_CR_RETURN(state_index,                                             \
  |  |  |  |  |  |  ------------------
  |  |  |  |  |  |  |  | 4248|      0|  do {                                                                         \
  |  |  |  |  |  |  |  | 4249|      0|    status = result;                                                           \
  |  |  |  |  |  |  |  |  ------------------
  |  |  |  |  |  |  |  |  |  Branch (4249:14): [True: 0, False: 0]
  |  |  |  |  |  |  |  |  ------------------
  |  |  |  |  |  |  |  | 4250|      0|    r->m_state = state_index;                                                  \
  |  |  |  |  |  |  |  | 4251|      0|    goto common_exit;                                                          \
  |  |  |  |  |  |  |  | 4252|      0|  case state_index:;                                                           \
  |  |  |  |  |  |  |  |  ------------------
  |  |  |  |  |  |  |  |  |  Branch (4252:3): [True: 0, False: 468]
  |  |  |  |  |  |  |  |  ------------------
  |  |  |  |  |  |  |  | 4253|      0|  }                                                                            \
  |  |  |  |  |  |  |  | 4254|      0|  MZ_MACRO_END
  |  |  |  |  |  |  |  |  ------------------
  |  |  |  |  |  |  |  |  |  |  726|      0|#define MZ_MACRO_END while (0)
  |  |  |  |  |  |  |  |  |  |  ------------------
  |  |  |  |  |  |  |  |  |  |  |  Branch (726:29): [Folded, False: 0]
  |  |  |  |  |  |  |  |  |  |  ------------------
  |  |  |  |  |  |  |  |  ------------------
  |  |  |  |  |  |  ------------------
  |  |  |  |  |  | 4268|      0|                      (decomp_flags & TINFL_FLAG_HAS_MORE_INPUT)               \
  |  |  |  |  |  | 4269|      0|                          ? TINFL_STATUS_NEEDS_MORE_INPUT                      \
  |  |  |  |  |  | 4270|      0|                          : TINFL_STATUS_FAILED_CANNOT_MAKE_PROGRESS);         \
  |  |  |  |  |  | 4271|      0|    }                                                                          \
  |  |  |  |  |  | 4272|      0|    c = *pIn_buf_cur++;                                                        \
  |  |  |  |  |  | 4273|      0|  }                                                                            \
  |  |  |  |  |  | 4274|      0|  MZ_MACRO_END
  |  |  |  |  |  |  ------------------
  |  |  |  |  |  |  |  |  726|      0|#define MZ_MACRO_END while (0)
  |  |  |  |  |  |  |  |  ------------------
  |  |  |  |  |  |  |  |  |  Branch (726:29): [Folded, False: 0]
  |  |  |  |  |  |  |  |  ------------------
  |  |  |  |  |  |  ------------------
  |  |  |  |  ------------------
  |  |  |  | 4280|      0|    bit_buf |= (((tinfl_bit_buf_t)c) << num_bits);                             \
  |  |  |  | 4281|      0|    num_bits += 8;                                                             \
  |  |  |  | 4282|      0|  } while (num_bits < (mz_uint)(n))
  |  |  |  |  ------------------
  |  |  |  |  |  Branch (4282:12): [True: 0, False: 0]
  |  |  |  |  ------------------
  |  |  ------------------
  |  | 4287|      0|    }                                                                          \
  |  | 4288|    264|    bit_buf >>= (n);                                                           \
  |  | 4289|    264|    num_bits -= (n);                                                           \
  |  | 4290|    264|  }                                                                            \
  |  | 4291|    264|  MZ_MACRO_END
  |  |  ------------------
  |  |  |  |  726|    264|#define MZ_MACRO_END while (0)
  |  |  |  |  ------------------
  |  |  |  |  |  Branch (726:29): [Folded, False: 264]
  |  |  |  |  ------------------
  |  |  ------------------
  ------------------
 4469|  1.31k|      for (counter = 0; counter < 4; ++counter) {
  ------------------
  |  Branch (4469:25): [True: 1.05k, False: 261]
  ------------------
 4470|  1.05k|        if (num_bits)
  ------------------
  |  Branch (4470:13): [True: 713, False: 343]
  ------------------
 4471|    713|          TINFL_GET_BITS(6, r->m_raw_header[counter], 8);
  ------------------
  |  | 4293|    713|  do {                                                                         \
  |  | 4294|    713|    if (num_bits < (mz_uint)(n)) {                                             \
  |  |  ------------------
  |  |  |  Branch (4294:9): [True: 0, False: 713]
  |  |  ------------------
  |  | 4295|      0|      TINFL_NEED_BITS(state_index, n);                                         \
  |  |  ------------------
  |  |  |  | 4277|      0|  do {                                                                         \
  |  |  |  | 4278|      0|    mz_uint c;                                                                 \
  |  |  |  | 4279|      0|    TINFL_GET_BYTE(state_index, c);                                            \
  |  |  |  |  ------------------
  |  |  |  |  |  | 4265|      0|  do {                                                                         \
  |  |  |  |  |  | 4266|      0|    while (pIn_buf_cur >= pIn_buf_end) {                                       \
  |  |  |  |  |  |  ------------------
  |  |  |  |  |  |  |  Branch (4266:12): [True: 0, False: 0]
  |  |  |  |  |  |  ------------------
  |  |  |  |  |  | 4267|      0|      TINFL_CR_RETURN(state_index,                                             \
  |  |  |  |  |  |  ------------------
  |  |  |  |  |  |  |  | 4248|      0|  do {                                                                         \
  |  |  |  |  |  |  |  | 4249|      0|    status = result;                                                           \
  |  |  |  |  |  |  |  |  ------------------
  |  |  |  |  |  |  |  |  |  Branch (4249:14): [True: 0, False: 0]
  |  |  |  |  |  |  |  |  ------------------
  |  |  |  |  |  |  |  | 4250|      0|    r->m_state = state_index;                                                  \
  |  |  |  |  |  |  |  | 4251|      0|    goto common_exit;                                                          \
  |  |  |  |  |  |  |  | 4252|      0|  case state_index:;                                                           \
  |  |  |  |  |  |  |  |  ------------------
  |  |  |  |  |  |  |  |  |  Branch (4252:3): [True: 0, False: 468]
  |  |  |  |  |  |  |  |  ------------------
  |  |  |  |  |  |  |  | 4253|      0|  }                                                                            \
  |  |  |  |  |  |  |  | 4254|      0|  MZ_MACRO_END
  |  |  |  |  |  |  |  |  ------------------
  |  |  |  |  |  |  |  |  |  |  726|      0|#define MZ_MACRO_END while (0)
  |  |  |  |  |  |  |  |  |  |  ------------------
  |  |  |  |  |  |  |  |  |  |  |  Branch (726:29): [Folded, False: 0]
  |  |  |  |  |  |  |  |  |  |  ------------------
  |  |  |  |  |  |  |  |  ------------------
  |  |  |  |  |  |  ------------------
  |  |  |  |  |  | 4268|      0|                      (decomp_flags & TINFL_FLAG_HAS_MORE_INPUT)               \
  |  |  |  |  |  | 4269|      0|                          ? TINFL_STATUS_NEEDS_MORE_INPUT                      \
  |  |  |  |  |  | 4270|      0|                          : TINFL_STATUS_FAILED_CANNOT_MAKE_PROGRESS);         \
  |  |  |  |  |  | 4271|      0|    }                                                                          \
  |  |  |  |  |  | 4272|      0|    c = *pIn_buf_cur++;                                                        \
  |  |  |  |  |  | 4273|      0|  }                                                                            \
  |  |  |  |  |  | 4274|      0|  MZ_MACRO_END
  |  |  |  |  |  |  ------------------
  |  |  |  |  |  |  |  |  726|      0|#define MZ_MACRO_END while (0)
  |  |  |  |  |  |  |  |  ------------------
  |  |  |  |  |  |  |  |  |  Branch (726:29): [Folded, False: 0]
  |  |  |  |  |  |  |  |  ------------------
  |  |  |  |  |  |  ------------------
  |  |  |  |  ------------------
  |  |  |  | 4280|      0|    bit_buf |= (((tinfl_bit_buf_t)c) << num_bits);                             \
  |  |  |  | 4281|      0|    num_bits += 8;                                                             \
  |  |  |  | 4282|      0|  } while (num_bits < (mz_uint)(n))
  |  |  |  |  ------------------
  |  |  |  |  |  Branch (4282:12): [True: 0, False: 0]
  |  |  |  |  ------------------
  |  |  ------------------
  |  | 4296|      0|    }                                                                          \
  |  | 4297|    713|    b = bit_buf & ((1 << (n)) - 1);                                            \
  |  | 4298|    713|    bit_buf >>= (n);                                                           \
  |  | 4299|    713|    num_bits -= (n);                                                           \
  |  | 4300|    713|  }                                                                            \
  |  | 4301|    713|  MZ_MACRO_END
  |  |  ------------------
  |  |  |  |  726|    713|#define MZ_MACRO_END while (0)
  |  |  |  |  ------------------
  |  |  |  |  |  Branch (726:29): [Folded, False: 713]
  |  |  |  |  ------------------
  |  |  ------------------
  ------------------
 4472|    343|        else
 4473|    343|          TINFL_GET_BYTE(7, r->m_raw_header[counter]);
  ------------------
  |  | 4265|    343|  do {                                                                         \
  |  | 4266|    343|    while (pIn_buf_cur >= pIn_buf_end) {                                       \
  |  |  ------------------
  |  |  |  Branch (4266:12): [True: 3, False: 340]
  |  |  ------------------
  |  | 4267|      3|      TINFL_CR_RETURN(state_index,                                             \
  |  |  ------------------
  |  |  |  | 4248|      3|  do {                                                                         \
  |  |  |  | 4249|      6|    status = result;                                                           \
  |  |  |  |  ------------------
  |  |  |  |  |  Branch (4249:14): [True: 0, False: 3]
  |  |  |  |  ------------------
  |  |  |  | 4250|      3|    r->m_state = state_index;                                                  \
  |  |  |  | 4251|      3|    goto common_exit;                                                          \
  |  |  |  | 4252|      3|  case state_index:;                                                           \
  |  |  |  |  ------------------
  |  |  |  |  |  Branch (4252:3): [True: 0, False: 468]
  |  |  |  |  ------------------
  |  |  |  | 4253|      0|  }                                                                            \
  |  |  |  | 4254|      3|  MZ_MACRO_END
  |  |  |  |  ------------------
  |  |  |  |  |  |  726|      3|#define MZ_MACRO_END while (0)
  |  |  |  |  |  |  ------------------
  |  |  |  |  |  |  |  Branch (726:29): [Folded, False: 0]
  |  |  |  |  |  |  ------------------
  |  |  |  |  ------------------
  |  |  ------------------
  |  | 4268|      3|                      (decomp_flags & TINFL_FLAG_HAS_MORE_INPUT)               \
  |  | 4269|      3|                          ? TINFL_STATUS_NEEDS_MORE_INPUT                      \
  |  | 4270|      3|                          : TINFL_STATUS_FAILED_CANNOT_MAKE_PROGRESS);         \
  |  | 4271|      3|    }                                                                          \
  |  | 4272|    343|    c = *pIn_buf_cur++;                                                        \
  |  | 4273|    340|  }                                                                            \
  |  | 4274|    343|  MZ_MACRO_END
  |  |  ------------------
  |  |  |  |  726|    343|#define MZ_MACRO_END while (0)
  |  |  |  |  ------------------
  |  |  |  |  |  Branch (726:29): [Folded, False: 340]
  |  |  |  |  ------------------
  |  |  ------------------
  ------------------
 4474|  1.05k|      }
 4475|    261|      if ((counter = (r->m_raw_header[0] | (r->m_raw_header[1] << 8))) !=
  ------------------
  |  Branch (4475:11): [True: 14, False: 247]
  ------------------
 4476|    261|          (mz_uint)(0xFFFF ^
 4477|    261|                    (r->m_raw_header[2] | (r->m_raw_header[3] << 8)))) {
 4478|     14|        TINFL_CR_RETURN_FOREVER(39, TINFL_STATUS_FAILED);
  ------------------
  |  | 4256|     14|  do {                                                                         \
  |  | 4257|     14|    for (;;) {                                                                 \
  |  | 4258|     14|      TINFL_CR_RETURN(state_index, result);                                    \
  |  |  ------------------
  |  |  |  | 4248|     14|  do {                                                                         \
  |  |  |  | 4249|     14|    status = result;                                                           \
  |  |  |  | 4250|     14|    r->m_state = state_index;                                                  \
  |  |  |  | 4251|     14|    goto common_exit;                                                          \
  |  |  |  | 4252|     14|  case state_index:;                                                           \
  |  |  |  |  ------------------
  |  |  |  |  |  Branch (4252:3): [True: 0, False: 468]
  |  |  |  |  ------------------
  |  |  |  | 4253|      0|  }                                                                            \
  |  |  |  | 4254|     14|  MZ_MACRO_END
  |  |  |  |  ------------------
  |  |  |  |  |  |  726|     14|#define MZ_MACRO_END while (0)
  |  |  |  |  |  |  ------------------
  |  |  |  |  |  |  |  Branch (726:29): [Folded, False: 0]
  |  |  |  |  |  |  ------------------
  |  |  |  |  ------------------
  |  |  ------------------
  |  | 4259|     14|    }                                                                          \
  |  | 4260|     14|  }                                                                            \
  |  | 4261|     14|  MZ_MACRO_END
  |  |  ------------------
  |  |  |  |  726|     14|#define MZ_MACRO_END while (0)
  |  |  |  |  ------------------
  |  |  |  |  |  Branch (726:29): [Folded, False: 0]
  |  |  |  |  ------------------
  |  |  ------------------
  ------------------
 4479|     14|      }
 4480|    295|      while ((counter) && (num_bits)) {
  ------------------
  |  Branch (4480:14): [True: 199, False: 96]
  |  Branch (4480:27): [True: 48, False: 151]
  ------------------
 4481|     48|        TINFL_GET_BITS(51, dist, 8);
  ------------------
  |  | 4293|     48|  do {                                                                         \
  |  | 4294|     48|    if (num_bits < (mz_uint)(n)) {                                             \
  |  |  ------------------
  |  |  |  Branch (4294:9): [True: 0, False: 48]
  |  |  ------------------
  |  | 4295|      0|      TINFL_NEED_BITS(state_index, n);                                         \
  |  |  ------------------
  |  |  |  | 4277|      0|  do {                                                                         \
  |  |  |  | 4278|      0|    mz_uint c;                                                                 \
  |  |  |  | 4279|      0|    TINFL_GET_BYTE(state_index, c);                                            \
  |  |  |  |  ------------------
  |  |  |  |  |  | 4265|      0|  do {                                                                         \
  |  |  |  |  |  | 4266|      0|    while (pIn_buf_cur >= pIn_buf_end) {                                       \
  |  |  |  |  |  |  ------------------
  |  |  |  |  |  |  |  Branch (4266:12): [True: 0, False: 0]
  |  |  |  |  |  |  ------------------
  |  |  |  |  |  | 4267|      0|      TINFL_CR_RETURN(state_index,                                             \
  |  |  |  |  |  |  ------------------
  |  |  |  |  |  |  |  | 4248|      0|  do {                                                                         \
  |  |  |  |  |  |  |  | 4249|      0|    status = result;                                                           \
  |  |  |  |  |  |  |  |  ------------------
  |  |  |  |  |  |  |  |  |  Branch (4249:14): [True: 0, False: 0]
  |  |  |  |  |  |  |  |  ------------------
  |  |  |  |  |  |  |  | 4250|      0|    r->m_state = state_index;                                                  \
  |  |  |  |  |  |  |  | 4251|      0|    goto common_exit;                                                          \
  |  |  |  |  |  |  |  | 4252|      0|  case state_index:;                                                           \
  |  |  |  |  |  |  |  |  ------------------
  |  |  |  |  |  |  |  |  |  Branch (4252:3): [True: 0, False: 468]
  |  |  |  |  |  |  |  |  ------------------
  |  |  |  |  |  |  |  | 4253|      0|  }                                                                            \
  |  |  |  |  |  |  |  | 4254|      0|  MZ_MACRO_END
  |  |  |  |  |  |  |  |  ------------------
  |  |  |  |  |  |  |  |  |  |  726|      0|#define MZ_MACRO_END while (0)
  |  |  |  |  |  |  |  |  |  |  ------------------
  |  |  |  |  |  |  |  |  |  |  |  Branch (726:29): [Folded, False: 0]
  |  |  |  |  |  |  |  |  |  |  ------------------
  |  |  |  |  |  |  |  |  ------------------
  |  |  |  |  |  |  ------------------
  |  |  |  |  |  | 4268|      0|                      (decomp_flags & TINFL_FLAG_HAS_MORE_INPUT)               \
  |  |  |  |  |  | 4269|      0|                          ? TINFL_STATUS_NEEDS_MORE_INPUT                      \
  |  |  |  |  |  | 4270|      0|                          : TINFL_STATUS_FAILED_CANNOT_MAKE_PROGRESS);         \
  |  |  |  |  |  | 4271|      0|    }                                                                          \
  |  |  |  |  |  | 4272|      0|    c = *pIn_buf_cur++;                                                        \
  |  |  |  |  |  | 4273|      0|  }                                                                            \
  |  |  |  |  |  | 4274|      0|  MZ_MACRO_END
  |  |  |  |  |  |  ------------------
  |  |  |  |  |  |  |  |  726|      0|#define MZ_MACRO_END while (0)
  |  |  |  |  |  |  |  |  ------------------
  |  |  |  |  |  |  |  |  |  Branch (726:29): [Folded, False: 0]
  |  |  |  |  |  |  |  |  ------------------
  |  |  |  |  |  |  ------------------
  |  |  |  |  ------------------
  |  |  |  | 4280|      0|    bit_buf |= (((tinfl_bit_buf_t)c) << num_bits);                             \
  |  |  |  | 4281|      0|    num_bits += 8;                                                             \
  |  |  |  | 4282|      0|  } while (num_bits < (mz_uint)(n))
  |  |  |  |  ------------------
  |  |  |  |  |  Branch (4282:12): [True: 0, False: 0]
  |  |  |  |  ------------------
  |  |  ------------------
  |  | 4296|      0|    }                                                                          \
  |  | 4297|     48|    b = bit_buf & ((1 << (n)) - 1);                                            \
  |  | 4298|     48|    bit_buf >>= (n);                                                           \
  |  | 4299|     48|    num_bits -= (n);                                                           \
  |  | 4300|     48|  }                                                                            \
  |  | 4301|     48|  MZ_MACRO_END
  |  |  ------------------
  |  |  |  |  726|     48|#define MZ_MACRO_END while (0)
  |  |  |  |  ------------------
  |  |  |  |  |  Branch (726:29): [Folded, False: 48]
  |  |  |  |  ------------------
  |  |  ------------------
  ------------------
 4482|     48|        while (pOut_buf_cur >= pOut_buf_end) {
  ------------------
  |  Branch (4482:16): [True: 0, False: 48]
  ------------------
 4483|      0|          TINFL_CR_RETURN(52, TINFL_STATUS_HAS_MORE_OUTPUT);
  ------------------
  |  | 4248|      0|  do {                                                                         \
  |  | 4249|      0|    status = result;                                                           \
  |  | 4250|      0|    r->m_state = state_index;                                                  \
  |  | 4251|      0|    goto common_exit;                                                          \
  |  | 4252|      0|  case state_index:;                                                           \
  |  |  ------------------
  |  |  |  Branch (4252:3): [True: 0, False: 468]
  |  |  ------------------
  |  | 4253|      0|  }                                                                            \
  |  | 4254|      0|  MZ_MACRO_END
  |  |  ------------------
  |  |  |  |  726|      0|#define MZ_MACRO_END while (0)
  |  |  |  |  ------------------
  |  |  |  |  |  Branch (726:29): [Folded, False: 0]
  |  |  |  |  ------------------
  |  |  ------------------
  ------------------
 4484|      0|        }
 4485|     48|        *pOut_buf_cur++ = (mz_uint8)dist;
 4486|     48|        counter--;
 4487|     48|      }
 4488|    398|      while (counter) {
  ------------------
  |  Branch (4488:14): [True: 182, False: 216]
  ------------------
 4489|    182|        size_t n;
 4490|    182|        while (pOut_buf_cur >= pOut_buf_end) {
  ------------------
  |  Branch (4490:16): [True: 15, False: 167]
  ------------------
 4491|     15|          TINFL_CR_RETURN(9, TINFL_STATUS_HAS_MORE_OUTPUT);
  ------------------
  |  | 4248|     15|  do {                                                                         \
  |  | 4249|     15|    status = result;                                                           \
  |  | 4250|     15|    r->m_state = state_index;                                                  \
  |  | 4251|     15|    goto common_exit;                                                          \
  |  | 4252|     15|  case state_index:;                                                           \
  |  |  ------------------
  |  |  |  Branch (4252:3): [True: 0, False: 468]
  |  |  ------------------
  |  | 4253|      0|  }                                                                            \
  |  | 4254|     15|  MZ_MACRO_END
  |  |  ------------------
  |  |  |  |  726|     15|#define MZ_MACRO_END while (0)
  |  |  |  |  ------------------
  |  |  |  |  |  Branch (726:29): [Folded, False: 0]
  |  |  |  |  ------------------
  |  |  ------------------
  ------------------
 4492|     15|        }
 4493|    167|        while (pIn_buf_cur >= pIn_buf_end) {
  ------------------
  |  Branch (4493:16): [True: 16, False: 151]
  ------------------
 4494|     16|          TINFL_CR_RETURN(38, (decomp_flags & TINFL_FLAG_HAS_MORE_INPUT)
  ------------------
  |  | 4248|     16|  do {                                                                         \
  |  | 4249|     32|    status = result;                                                           \
  |  |  ------------------
  |  |  |  Branch (4249:14): [True: 0, False: 16]
  |  |  ------------------
  |  | 4250|     16|    r->m_state = state_index;                                                  \
  |  | 4251|     16|    goto common_exit;                                                          \
  |  | 4252|     16|  case state_index:;                                                           \
  |  |  ------------------
  |  |  |  Branch (4252:3): [True: 0, False: 468]
  |  |  ------------------
  |  | 4253|      0|  }                                                                            \
  |  | 4254|     16|  MZ_MACRO_END
  |  |  ------------------
  |  |  |  |  726|     16|#define MZ_MACRO_END while (0)
  |  |  |  |  ------------------
  |  |  |  |  |  Branch (726:29): [Folded, False: 0]
  |  |  |  |  ------------------
  |  |  ------------------
  ------------------
 4495|     16|                                  ? TINFL_STATUS_NEEDS_MORE_INPUT
 4496|     16|                                  : TINFL_STATUS_FAILED_CANNOT_MAKE_PROGRESS);
 4497|     16|        }
 4498|    151|        n = MZ_MIN(MZ_MIN((size_t)(pOut_buf_end - pOut_buf_cur),
  ------------------
  |  |  759|    302|#define MZ_MIN(a, b) (((a) < (b)) ? (a) : (b))
  |  |  ------------------
  |  |  |  Branch (759:23): [True: 31, False: 120]
  |  |  |  Branch (759:25): [True: 72, False: 79]
  |  |  |  Branch (759:38): [True: 14, False: 17]
  |  |  ------------------
  ------------------
 4499|    151|                          (size_t)(pIn_buf_end - pIn_buf_cur)),
 4500|    151|                   counter);
 4501|    151|        TINFL_MEMCPY(pOut_buf_cur, pIn_buf_cur, n);
  ------------------
  |  | 4241|    151|#define TINFL_MEMCPY(d, s, l) memcpy(d, s, l)
  ------------------
 4502|    151|        pIn_buf_cur += n;
 4503|    151|        pOut_buf_cur += n;
 4504|    151|        counter -= (mz_uint)n;
 4505|    151|      }
 4506|  1.44k|    } else if (r->m_type == 3) {
  ------------------
  |  Branch (4506:16): [True: 2, False: 1.44k]
  ------------------
 4507|      2|      TINFL_CR_RETURN_FOREVER(10, TINFL_STATUS_FAILED);
  ------------------
  |  | 4256|      2|  do {                                                                         \
  |  | 4257|      2|    for (;;) {                                                                 \
  |  | 4258|      2|      TINFL_CR_RETURN(state_index, result);                                    \
  |  |  ------------------
  |  |  |  | 4248|      2|  do {                                                                         \
  |  |  |  | 4249|      2|    status = result;                                                           \
  |  |  |  | 4250|      2|    r->m_state = state_index;                                                  \
  |  |  |  | 4251|      2|    goto common_exit;                                                          \
  |  |  |  | 4252|      2|  case state_index:;                                                           \
  |  |  |  |  ------------------
  |  |  |  |  |  Branch (4252:3): [True: 0, False: 468]
  |  |  |  |  ------------------
  |  |  |  | 4253|      0|  }                                                                            \
  |  |  |  | 4254|      2|  MZ_MACRO_END
  |  |  |  |  ------------------
  |  |  |  |  |  |  726|      2|#define MZ_MACRO_END while (0)
  |  |  |  |  |  |  ------------------
  |  |  |  |  |  |  |  Branch (726:29): [Folded, False: 0]
  |  |  |  |  |  |  ------------------
  |  |  |  |  ------------------
  |  |  ------------------
  |  | 4259|      2|    }                                                                          \
  |  | 4260|      2|  }                                                                            \
  |  | 4261|      2|  MZ_MACRO_END
  |  |  ------------------
  |  |  |  |  726|      2|#define MZ_MACRO_END while (0)
  |  |  |  |  ------------------
  |  |  |  |  |  Branch (726:29): [Folded, False: 0]
  |  |  |  |  ------------------
  |  |  ------------------
  ------------------
 4508|  1.44k|    } else {
 4509|  1.44k|      if (r->m_type == 1) {
  ------------------
  |  Branch (4509:11): [True: 1.04k, False: 397]
  ------------------
 4510|  1.04k|        mz_uint8 *p = r->m_code_size_0;
 4511|  1.04k|        mz_uint i;
 4512|  1.04k|        r->m_table_sizes[0] = 288;
 4513|  1.04k|        r->m_table_sizes[1] = 32;
 4514|  1.04k|        TINFL_MEMSET(r->m_code_size_1, 5, 32);
  ------------------
  |  | 4242|  1.04k|#define TINFL_MEMSET(p, c, l) memset(p, c, l)
  ------------------
 4515|   151k|        for (i = 0; i <= 143; ++i)
  ------------------
  |  Branch (4515:21): [True: 150k, False: 1.04k]
  ------------------
 4516|   150k|          *p++ = 8;
 4517|   118k|        for (; i <= 255; ++i)
  ------------------
  |  Branch (4517:16): [True: 117k, False: 1.04k]
  ------------------
 4518|   117k|          *p++ = 9;
 4519|  26.1k|        for (; i <= 279; ++i)
  ------------------
  |  Branch (4519:16): [True: 25.1k, False: 1.04k]
  ------------------
 4520|  25.1k|          *p++ = 7;
 4521|  9.41k|        for (; i <= 287; ++i)
  ------------------
  |  Branch (4521:16): [True: 8.36k, False: 1.04k]
  ------------------
 4522|  8.36k|          *p++ = 8;
 4523|  1.04k|      } else {
 4524|  1.58k|        for (counter = 0; counter < 3; counter++) {
  ------------------
  |  Branch (4524:27): [True: 1.19k, False: 396]
  ------------------
 4525|  1.19k|          TINFL_GET_BITS(11, r->m_table_sizes[counter], "\05\05\04"[counter]);
  ------------------
  |  | 4293|  1.19k|  do {                                                                         \
  |  | 4294|  1.19k|    if (num_bits < (mz_uint)(n)) {                                             \
  |  |  ------------------
  |  |  |  Branch (4294:9): [True: 184, False: 1.00k]
  |  |  ------------------
  |  | 4295|    184|      TINFL_NEED_BITS(state_index, n);                                         \
  |  |  ------------------
  |  |  |  | 4277|    184|  do {                                                                         \
  |  |  |  | 4278|    184|    mz_uint c;                                                                 \
  |  |  |  | 4279|    184|    TINFL_GET_BYTE(state_index, c);                                            \
  |  |  |  |  ------------------
  |  |  |  |  |  | 4265|    184|  do {                                                                         \
  |  |  |  |  |  | 4266|    184|    while (pIn_buf_cur >= pIn_buf_end) {                                       \
  |  |  |  |  |  |  ------------------
  |  |  |  |  |  |  |  Branch (4266:12): [True: 1, False: 183]
  |  |  |  |  |  |  ------------------
  |  |  |  |  |  | 4267|      1|      TINFL_CR_RETURN(state_index,                                             \
  |  |  |  |  |  |  ------------------
  |  |  |  |  |  |  |  | 4248|      1|  do {                                                                         \
  |  |  |  |  |  |  |  | 4249|      2|    status = result;                                                           \
  |  |  |  |  |  |  |  |  ------------------
  |  |  |  |  |  |  |  |  |  Branch (4249:14): [True: 0, False: 1]
  |  |  |  |  |  |  |  |  ------------------
  |  |  |  |  |  |  |  | 4250|      1|    r->m_state = state_index;                                                  \
  |  |  |  |  |  |  |  | 4251|      1|    goto common_exit;                                                          \
  |  |  |  |  |  |  |  | 4252|      1|  case state_index:;                                                           \
  |  |  |  |  |  |  |  |  ------------------
  |  |  |  |  |  |  |  |  |  Branch (4252:3): [True: 0, False: 468]
  |  |  |  |  |  |  |  |  ------------------
  |  |  |  |  |  |  |  | 4253|      0|  }                                                                            \
  |  |  |  |  |  |  |  | 4254|      1|  MZ_MACRO_END
  |  |  |  |  |  |  |  |  ------------------
  |  |  |  |  |  |  |  |  |  |  726|      1|#define MZ_MACRO_END while (0)
  |  |  |  |  |  |  |  |  |  |  ------------------
  |  |  |  |  |  |  |  |  |  |  |  Branch (726:29): [Folded, False: 0]
  |  |  |  |  |  |  |  |  |  |  ------------------
  |  |  |  |  |  |  |  |  ------------------
  |  |  |  |  |  |  ------------------
  |  |  |  |  |  | 4268|      1|                      (decomp_flags & TINFL_FLAG_HAS_MORE_INPUT)               \
  |  |  |  |  |  | 4269|      1|                          ? TINFL_STATUS_NEEDS_MORE_INPUT                      \
  |  |  |  |  |  | 4270|      1|                          : TINFL_STATUS_FAILED_CANNOT_MAKE_PROGRESS);         \
  |  |  |  |  |  | 4271|      1|    }                                                                          \
  |  |  |  |  |  | 4272|    184|    c = *pIn_buf_cur++;                                                        \
  |  |  |  |  |  | 4273|    183|  }                                                                            \
  |  |  |  |  |  | 4274|    184|  MZ_MACRO_END
  |  |  |  |  |  |  ------------------
  |  |  |  |  |  |  |  |  726|    184|#define MZ_MACRO_END while (0)
  |  |  |  |  |  |  |  |  ------------------
  |  |  |  |  |  |  |  |  |  Branch (726:29): [Folded, False: 183]
  |  |  |  |  |  |  |  |  ------------------
  |  |  |  |  |  |  ------------------
  |  |  |  |  ------------------
  |  |  |  | 4280|    184|    bit_buf |= (((tinfl_bit_buf_t)c) << num_bits);                             \
  |  |  |  | 4281|    183|    num_bits += 8;                                                             \
  |  |  |  | 4282|    183|  } while (num_bits < (mz_uint)(n))
  |  |  |  |  ------------------
  |  |  |  |  |  Branch (4282:12): [True: 0, False: 183]
  |  |  |  |  ------------------
  |  |  ------------------
  |  | 4296|    184|    }                                                                          \
  |  | 4297|  1.19k|    b = bit_buf & ((1 << (n)) - 1);                                            \
  |  | 4298|  1.19k|    bit_buf >>= (n);                                                           \
  |  | 4299|  1.19k|    num_bits -= (n);                                                           \
  |  | 4300|  1.19k|  }                                                                            \
  |  | 4301|  1.19k|  MZ_MACRO_END
  |  |  ------------------
  |  |  |  |  726|  1.19k|#define MZ_MACRO_END while (0)
  |  |  |  |  ------------------
  |  |  |  |  |  Branch (726:29): [Folded, False: 1.19k]
  |  |  |  |  ------------------
  |  |  ------------------
  ------------------
 4526|  1.19k|          r->m_table_sizes[counter] += s_min_table_sizes[counter];
 4527|  1.19k|        }
 4528|    396|        MZ_CLEAR_ARR(r->m_code_size_2);
  ------------------
  |  |  761|    396|#define MZ_CLEAR_ARR(obj) memset((obj), 0, sizeof(obj))
  ------------------
 4529|  6.85k|        for (counter = 0; counter < r->m_table_sizes[2]; counter++) {
  ------------------
  |  Branch (4529:27): [True: 6.46k, False: 393]
  ------------------
 4530|  6.46k|          mz_uint s;
 4531|  6.46k|          TINFL_GET_BITS(14, s, 3);
  ------------------
  |  | 4293|  6.46k|  do {                                                                         \
  |  | 4294|  6.46k|    if (num_bits < (mz_uint)(n)) {                                             \
  |  |  ------------------
  |  |  |  Branch (4294:9): [True: 1.80k, False: 4.65k]
  |  |  ------------------
  |  | 4295|  1.80k|      TINFL_NEED_BITS(state_index, n);                                         \
  |  |  ------------------
  |  |  |  | 4277|  1.80k|  do {                                                                         \
  |  |  |  | 4278|  1.80k|    mz_uint c;                                                                 \
  |  |  |  | 4279|  1.80k|    TINFL_GET_BYTE(state_index, c);                                            \
  |  |  |  |  ------------------
  |  |  |  |  |  | 4265|  1.80k|  do {                                                                         \
  |  |  |  |  |  | 4266|  1.80k|    while (pIn_buf_cur >= pIn_buf_end) {                                       \
  |  |  |  |  |  |  ------------------
  |  |  |  |  |  |  |  Branch (4266:12): [True: 3, False: 1.80k]
  |  |  |  |  |  |  ------------------
  |  |  |  |  |  | 4267|      3|      TINFL_CR_RETURN(state_index,                                             \
  |  |  |  |  |  |  ------------------
  |  |  |  |  |  |  |  | 4248|      3|  do {                                                                         \
  |  |  |  |  |  |  |  | 4249|      6|    status = result;                                                           \
  |  |  |  |  |  |  |  |  ------------------
  |  |  |  |  |  |  |  |  |  Branch (4249:14): [True: 0, False: 3]
  |  |  |  |  |  |  |  |  ------------------
  |  |  |  |  |  |  |  | 4250|      3|    r->m_state = state_index;                                                  \
  |  |  |  |  |  |  |  | 4251|      3|    goto common_exit;                                                          \
  |  |  |  |  |  |  |  | 4252|      3|  case state_index:;                                                           \
  |  |  |  |  |  |  |  |  ------------------
  |  |  |  |  |  |  |  |  |  Branch (4252:3): [True: 0, False: 468]
  |  |  |  |  |  |  |  |  ------------------
  |  |  |  |  |  |  |  | 4253|      0|  }                                                                            \
  |  |  |  |  |  |  |  | 4254|      3|  MZ_MACRO_END
  |  |  |  |  |  |  |  |  ------------------
  |  |  |  |  |  |  |  |  |  |  726|      3|#define MZ_MACRO_END while (0)
  |  |  |  |  |  |  |  |  |  |  ------------------
  |  |  |  |  |  |  |  |  |  |  |  Branch (726:29): [Folded, False: 0]
  |  |  |  |  |  |  |  |  |  |  ------------------
  |  |  |  |  |  |  |  |  ------------------
  |  |  |  |  |  |  ------------------
  |  |  |  |  |  | 4268|      3|                      (decomp_flags & TINFL_FLAG_HAS_MORE_INPUT)               \
  |  |  |  |  |  | 4269|      3|                          ? TINFL_STATUS_NEEDS_MORE_INPUT                      \
  |  |  |  |  |  | 4270|      3|                          : TINFL_STATUS_FAILED_CANNOT_MAKE_PROGRESS);         \
  |  |  |  |  |  | 4271|      3|    }                                                                          \
  |  |  |  |  |  | 4272|  1.80k|    c = *pIn_buf_cur++;                                                        \
  |  |  |  |  |  | 4273|  1.80k|  }                                                                            \
  |  |  |  |  |  | 4274|  1.80k|  MZ_MACRO_END
  |  |  |  |  |  |  ------------------
  |  |  |  |  |  |  |  |  726|  1.80k|#define MZ_MACRO_END while (0)
  |  |  |  |  |  |  |  |  ------------------
  |  |  |  |  |  |  |  |  |  Branch (726:29): [Folded, False: 1.80k]
  |  |  |  |  |  |  |  |  ------------------
  |  |  |  |  |  |  ------------------
  |  |  |  |  ------------------
  |  |  |  | 4280|  1.80k|    bit_buf |= (((tinfl_bit_buf_t)c) << num_bits);                             \
  |  |  |  | 4281|  1.80k|    num_bits += 8;                                                             \
  |  |  |  | 4282|  1.80k|  } while (num_bits < (mz_uint)(n))
  |  |  |  |  ------------------
  |  |  |  |  |  Branch (4282:12): [True: 0, False: 1.80k]
  |  |  |  |  ------------------
  |  |  ------------------
  |  | 4296|  1.80k|    }                                                                          \
  |  | 4297|  6.46k|    b = bit_buf & ((1 << (n)) - 1);                                            \
  |  | 4298|  6.45k|    bit_buf >>= (n);                                                           \
  |  | 4299|  6.45k|    num_bits -= (n);                                                           \
  |  | 4300|  6.45k|  }                                                                            \
  |  | 4301|  6.46k|  MZ_MACRO_END
  |  |  ------------------
  |  |  |  |  726|  6.46k|#define MZ_MACRO_END while (0)
  |  |  |  |  ------------------
  |  |  |  |  |  Branch (726:29): [Folded, False: 6.45k]
  |  |  |  |  ------------------
  |  |  ------------------
  ------------------
 4532|  6.45k|          r->m_code_size_2[s_length_dezigzag[counter]] = (mz_uint8)s;
 4533|  6.45k|        }
 4534|    393|        r->m_table_sizes[2] = 19;
 4535|    393|      }
 4536|  4.58k|      for (; (int)r->m_type >= 0; r->m_type--) {
  ------------------
  |  Branch (4536:14): [True: 3.19k, False: 1.38k]
  ------------------
 4537|  3.19k|        int tree_next, tree_cur;
 4538|  3.19k|        mz_int16 *pLookUp;
 4539|  3.19k|        mz_int16 *pTree;
 4540|  3.19k|        mz_uint8 *pCode_size;
 4541|  3.19k|        mz_uint i, j, used_syms, total, sym_index, next_code[17],
 4542|  3.19k|            total_syms[16];
 4543|  3.19k|        pLookUp = r->m_look_up[r->m_type];
 4544|  3.19k|        pTree = pTrees[r->m_type];
 4545|  3.19k|        pCode_size = pCode_sizes[r->m_type];
 4546|  3.19k|        MZ_CLEAR_ARR(total_syms);
  ------------------
  |  |  761|  3.19k|#define MZ_CLEAR_ARR(obj) memset((obj), 0, sizeof(obj))
  ------------------
 4547|  3.19k|        TINFL_MEMSET(pLookUp, 0, sizeof(r->m_look_up[0]));
  ------------------
  |  | 4242|  3.19k|#define TINFL_MEMSET(p, c, l) memset(p, c, l)
  ------------------
 4548|  3.19k|        tinfl_clear_tree(r);
 4549|   451k|        for (i = 0; i < r->m_table_sizes[r->m_type]; ++i)
  ------------------
  |  Branch (4549:21): [True: 448k, False: 3.19k]
  ------------------
 4550|   448k|          total_syms[pCode_size[i]]++;
 4551|  3.19k|        used_syms = 0, total = 0;
 4552|  3.19k|        next_code[0] = next_code[1] = 0;
 4553|  51.1k|        for (i = 1; i <= 15; ++i) {
  ------------------
  |  Branch (4553:21): [True: 47.9k, False: 3.19k]
  ------------------
 4554|  47.9k|          used_syms += total_syms[i];
 4555|  47.9k|          next_code[i + 1] = (total = ((total + total_syms[i]) << 1));
 4556|  47.9k|        }
 4557|  3.19k|        if ((65536 != total) && (used_syms > 1)) {
  ------------------
  |  Branch (4557:13): [True: 718, False: 2.48k]
  |  Branch (4557:33): [True: 34, False: 684]
  ------------------
 4558|     34|          TINFL_CR_RETURN_FOREVER(35, TINFL_STATUS_FAILED);
  ------------------
  |  | 4256|     34|  do {                                                                         \
  |  | 4257|     34|    for (;;) {                                                                 \
  |  | 4258|     34|      TINFL_CR_RETURN(state_index, result);                                    \
  |  |  ------------------
  |  |  |  | 4248|     34|  do {                                                                         \
  |  |  |  | 4249|     34|    status = result;                                                           \
  |  |  |  | 4250|     34|    r->m_state = state_index;                                                  \
  |  |  |  | 4251|     34|    goto common_exit;                                                          \
  |  |  |  | 4252|     34|  case state_index:;                                                           \
  |  |  |  |  ------------------
  |  |  |  |  |  Branch (4252:3): [True: 0, False: 468]
  |  |  |  |  ------------------
  |  |  |  | 4253|      0|  }                                                                            \
  |  |  |  | 4254|     34|  MZ_MACRO_END
  |  |  |  |  ------------------
  |  |  |  |  |  |  726|     34|#define MZ_MACRO_END while (0)
  |  |  |  |  |  |  ------------------
  |  |  |  |  |  |  |  Branch (726:29): [Folded, False: 0]
  |  |  |  |  |  |  ------------------
  |  |  |  |  ------------------
  |  |  ------------------
  |  | 4259|     34|    }                                                                          \
  |  | 4260|     34|  }                                                                            \
  |  | 4261|     34|  MZ_MACRO_END
  |  |  ------------------
  |  |  |  |  726|     34|#define MZ_MACRO_END while (0)
  |  |  |  |  ------------------
  |  |  |  |  |  Branch (726:29): [Folded, False: 0]
  |  |  |  |  ------------------
  |  |  ------------------
  ------------------
 4559|     34|        }
 4560|  3.16k|        for (tree_next = -1, sym_index = 0;
 4561|   446k|             sym_index < r->m_table_sizes[r->m_type]; ++sym_index) {
  ------------------
  |  Branch (4561:14): [True: 443k, False: 3.16k]
  ------------------
 4562|   443k|          mz_uint rev_code = 0, l, cur_code, code_size = pCode_size[sym_index];
 4563|   443k|          if (!code_size)
  ------------------
  |  Branch (4563:15): [True: 102k, False: 341k]
  ------------------
 4564|   102k|            continue;
 4565|   341k|          cur_code = next_code[code_size]++;
 4566|  3.05M|          for (l = code_size; l > 0; l--, cur_code >>= 1)
  ------------------
  |  Branch (4566:31): [True: 2.71M, False: 341k]
  ------------------
 4567|  2.71M|            rev_code = (rev_code << 1) | (cur_code & 1);
 4568|   341k|          if (code_size <= TINFL_FAST_LOOKUP_BITS) {
  ------------------
  |  Branch (4568:15): [True: 340k, False: 762]
  ------------------
 4569|   340k|            mz_int16 k = (mz_int16)((code_size << 9) | sym_index);
 4570|  2.90M|            while (rev_code < TINFL_FAST_LOOKUP_SIZE) {
  ------------------
  |  Branch (4570:20): [True: 2.56M, False: 340k]
  ------------------
 4571|  2.56M|              pLookUp[rev_code] = k;
 4572|  2.56M|              rev_code += (1 << code_size);
 4573|  2.56M|            }
 4574|   340k|            continue;
 4575|   340k|          }
 4576|    762|          if (0 ==
  ------------------
  |  Branch (4576:15): [True: 586, False: 176]
  ------------------
 4577|    762|              (tree_cur = pLookUp[rev_code & (TINFL_FAST_LOOKUP_SIZE - 1)])) {
 4578|    586|            pLookUp[rev_code & (TINFL_FAST_LOOKUP_SIZE - 1)] =
 4579|    586|                (mz_int16)tree_next;
 4580|    586|            tree_cur = tree_next;
 4581|    586|            tree_next -= 2;
 4582|    586|          }
 4583|    762|          rev_code >>= (TINFL_FAST_LOOKUP_BITS - 1);
 4584|  2.17k|          for (j = code_size; j > (TINFL_FAST_LOOKUP_BITS + 1); j--) {
  ------------------
  |  Branch (4584:31): [True: 1.40k, False: 762]
  ------------------
 4585|  1.40k|            tree_cur -= ((rev_code >>= 1) & 1);
 4586|  1.40k|            if (!pTree[-tree_cur - 1]) {
  ------------------
  |  Branch (4586:17): [True: 1.40k, False: 0]
  ------------------
 4587|  1.40k|              pTree[-tree_cur - 1] = (mz_int16)tree_next;
 4588|  1.40k|              tree_cur = tree_next;
 4589|  1.40k|              tree_next -= 2;
 4590|  1.40k|            } else
 4591|      0|              tree_cur = pTree[-tree_cur - 1];
 4592|  1.40k|          }
 4593|    762|          tree_cur -= ((rev_code >>= 1) & 1);
 4594|    762|          pTree[-tree_cur - 1] = (mz_int16)sym_index;
 4595|    762|        }
 4596|  3.16k|        if (r->m_type == 2) {
  ------------------
  |  Branch (4596:13): [True: 380, False: 2.78k]
  ------------------
 4597|    380|          for (counter = 0;
 4598|  63.7k|               counter < (r->m_table_sizes[0] + r->m_table_sizes[1]);) {
  ------------------
  |  Branch (4598:16): [True: 63.4k, False: 370]
  ------------------
 4599|  63.4k|            mz_uint s;
 4600|  63.4k|            TINFL_HUFF_DECODE(16, dist, r->m_look_up[2], r->m_tree_2);
  ------------------
  |  | 4348|  63.4k|  do {                                                                         \
  |  | 4349|  63.4k|    int temp;                                                                  \
  |  | 4350|  63.4k|    mz_uint code_len, c;                                                       \
  |  | 4351|  63.4k|    if (num_bits < 15) {                                                       \
  |  |  ------------------
  |  |  |  Branch (4351:9): [True: 6.24k, False: 57.1k]
  |  |  ------------------
  |  | 4352|  6.24k|      if ((pIn_buf_end - pIn_buf_cur) < 2) {                                   \
  |  |  ------------------
  |  |  |  Branch (4352:11): [True: 303, False: 5.93k]
  |  |  ------------------
  |  | 4353|    303|        TINFL_HUFF_BITBUF_FILL(state_index, pLookUp, pTree);                   \
  |  |  ------------------
  |  |  |  | 4313|    306|  do {                                                                         \
  |  |  |  | 4314|    306|    temp = pLookUp[bit_buf & (TINFL_FAST_LOOKUP_SIZE - 1)];                    \
  |  |  |  | 4315|    306|    if (temp >= 0) {                                                           \
  |  |  |  |  ------------------
  |  |  |  |  |  Branch (4315:9): [True: 306, False: 0]
  |  |  |  |  ------------------
  |  |  |  | 4316|    306|      code_len = temp >> 9;                                                    \
  |  |  |  | 4317|    306|      if ((code_len) && (num_bits >= code_len))                                \
  |  |  |  |  ------------------
  |  |  |  |  |  Branch (4317:11): [True: 303, False: 3]
  |  |  |  |  |  Branch (4317:25): [True: 291, False: 12]
  |  |  |  |  ------------------
  |  |  |  | 4318|    306|        break;                                                                 \
  |  |  |  | 4319|    306|    } else if (num_bits > TINFL_FAST_LOOKUP_BITS) {                            \
  |  |  |  |  ------------------
  |  |  |  |  |  Branch (4319:16): [True: 0, False: 0]
  |  |  |  |  ------------------
  |  |  |  | 4320|      0|      code_len = TINFL_FAST_LOOKUP_BITS;                                       \
  |  |  |  | 4321|      0|      do {                                                                     \
  |  |  |  | 4322|      0|        temp = pTree[~temp + ((bit_buf >> code_len++) & 1)];                   \
  |  |  |  | 4323|      0|      } while ((temp < 0) && (num_bits >= (code_len + 1)));                    \
  |  |  |  |  ------------------
  |  |  |  |  |  Branch (4323:16): [True: 0, False: 0]
  |  |  |  |  |  Branch (4323:30): [True: 0, False: 0]
  |  |  |  |  ------------------
  |  |  |  | 4324|      0|      if (temp >= 0)                                                           \
  |  |  |  |  ------------------
  |  |  |  |  |  Branch (4324:11): [True: 0, False: 0]
  |  |  |  |  ------------------
  |  |  |  | 4325|      0|        break;                                                                 \
  |  |  |  | 4326|      0|    }                                                                          \
  |  |  |  | 4327|    306|    TINFL_GET_BYTE(state_index, c);                                            \
  |  |  |  |  ------------------
  |  |  |  |  |  | 4265|     15|  do {                                                                         \
  |  |  |  |  |  | 4266|     15|    while (pIn_buf_cur >= pIn_buf_end) {                                       \
  |  |  |  |  |  |  ------------------
  |  |  |  |  |  |  |  Branch (4266:12): [True: 9, False: 6]
  |  |  |  |  |  |  ------------------
  |  |  |  |  |  | 4267|      9|      TINFL_CR_RETURN(state_index,                                             \
  |  |  |  |  |  |  ------------------
  |  |  |  |  |  |  |  | 4248|      9|  do {                                                                         \
  |  |  |  |  |  |  |  | 4249|     18|    status = result;                                                           \
  |  |  |  |  |  |  |  |  ------------------
  |  |  |  |  |  |  |  |  |  Branch (4249:14): [True: 0, False: 9]
  |  |  |  |  |  |  |  |  ------------------
  |  |  |  |  |  |  |  | 4250|      9|    r->m_state = state_index;                                                  \
  |  |  |  |  |  |  |  | 4251|      9|    goto common_exit;                                                          \
  |  |  |  |  |  |  |  | 4252|      9|  case state_index:;                                                           \
  |  |  |  |  |  |  |  |  ------------------
  |  |  |  |  |  |  |  |  |  Branch (4252:3): [True: 0, False: 468]
  |  |  |  |  |  |  |  |  ------------------
  |  |  |  |  |  |  |  | 4253|      0|  }                                                                            \
  |  |  |  |  |  |  |  | 4254|      9|  MZ_MACRO_END
  |  |  |  |  |  |  |  |  ------------------
  |  |  |  |  |  |  |  |  |  |  726|      9|#define MZ_MACRO_END while (0)
  |  |  |  |  |  |  |  |  |  |  ------------------
  |  |  |  |  |  |  |  |  |  |  |  Branch (726:29): [Folded, False: 0]
  |  |  |  |  |  |  |  |  |  |  ------------------
  |  |  |  |  |  |  |  |  ------------------
  |  |  |  |  |  |  ------------------
  |  |  |  |  |  | 4268|      9|                      (decomp_flags & TINFL_FLAG_HAS_MORE_INPUT)               \
  |  |  |  |  |  | 4269|      9|                          ? TINFL_STATUS_NEEDS_MORE_INPUT                      \
  |  |  |  |  |  | 4270|      9|                          : TINFL_STATUS_FAILED_CANNOT_MAKE_PROGRESS);         \
  |  |  |  |  |  | 4271|      9|    }                                                                          \
  |  |  |  |  |  | 4272|     15|    c = *pIn_buf_cur++;                                                        \
  |  |  |  |  |  | 4273|      6|  }                                                                            \
  |  |  |  |  |  | 4274|    306|  MZ_MACRO_END
  |  |  |  |  |  |  ------------------
  |  |  |  |  |  |  |  |  726|    306|#define MZ_MACRO_END while (0)
  |  |  |  |  |  |  |  |  ------------------
  |  |  |  |  |  |  |  |  |  Branch (726:29): [Folded, False: 6]
  |  |  |  |  |  |  |  |  ------------------
  |  |  |  |  |  |  ------------------
  |  |  |  |  ------------------
  |  |  |  | 4328|     15|    bit_buf |= (((tinfl_bit_buf_t)c) << num_bits);                             \
  |  |  |  | 4329|      6|    num_bits += 8;                                                             \
  |  |  |  | 4330|      6|  } while (num_bits < 15);
  |  |  |  |  ------------------
  |  |  |  |  |  Branch (4330:12): [True: 3, False: 3]
  |  |  |  |  ------------------
  |  |  ------------------
  |  | 4354|  5.93k|      } else {                                                                 \
  |  | 4355|  5.93k|        bit_buf |= (((tinfl_bit_buf_t)pIn_buf_cur[0]) << num_bits) |           \
  |  | 4356|  5.93k|                   (((tinfl_bit_buf_t)pIn_buf_cur[1]) << (num_bits + 8));      \
  |  | 4357|  5.93k|        pIn_buf_cur += 2;                                                      \
  |  | 4358|  5.93k|        num_bits += 16;                                                        \
  |  | 4359|  5.93k|      }                                                                        \
  |  | 4360|  6.24k|    }                                                                          \
  |  | 4361|  63.4k|    if ((temp = pLookUp[bit_buf & (TINFL_FAST_LOOKUP_SIZE - 1)]) >= 0)         \
  |  |  ------------------
  |  |  |  Branch (4361:9): [True: 63.3k, False: 0]
  |  |  ------------------
  |  | 4362|  63.3k|      code_len = temp >> 9, temp &= 511;                                       \
  |  | 4363|  63.3k|    else {                                                                     \
  |  | 4364|      0|      code_len = TINFL_FAST_LOOKUP_BITS;                                       \
  |  | 4365|      0|      do {                                                                     \
  |  | 4366|      0|        temp = pTree[~temp + ((bit_buf >> code_len++) & 1)];                   \
  |  | 4367|      0|      } while (temp < 0);                                                      \
  |  |  ------------------
  |  |  |  Branch (4367:16): [True: 0, False: 0]
  |  |  ------------------
  |  | 4368|      0|    }                                                                          \
  |  | 4369|  63.3k|    sym = temp;                                                                \
  |  | 4370|  63.3k|    bit_buf >>= code_len;                                                      \
  |  | 4371|  63.3k|    num_bits -= code_len;                                                      \
  |  | 4372|  63.3k|  }                                                                            \
  |  | 4373|  63.4k|  MZ_MACRO_END
  |  |  ------------------
  |  |  |  |  726|  63.4k|#define MZ_MACRO_END while (0)
  |  |  |  |  ------------------
  |  |  |  |  |  Branch (726:29): [Folded, False: 63.3k]
  |  |  |  |  ------------------
  |  |  ------------------
  ------------------
 4601|  63.3k|            if (dist < 16) {
  ------------------
  |  Branch (4601:17): [True: 60.6k, False: 2.77k]
  ------------------
 4602|  60.6k|              r->m_len_codes[counter++] = (mz_uint8)dist;
 4603|  60.6k|              continue;
 4604|  60.6k|            }
 4605|  2.77k|            if ((dist == 16) && (!counter)) {
  ------------------
  |  Branch (4605:17): [True: 528, False: 2.24k]
  |  Branch (4605:33): [True: 1, False: 527]
  ------------------
 4606|      1|              TINFL_CR_RETURN_FOREVER(17, TINFL_STATUS_FAILED);
  ------------------
  |  | 4256|      1|  do {                                                                         \
  |  | 4257|      1|    for (;;) {                                                                 \
  |  | 4258|      1|      TINFL_CR_RETURN(state_index, result);                                    \
  |  |  ------------------
  |  |  |  | 4248|      1|  do {                                                                         \
  |  |  |  | 4249|      1|    status = result;                                                           \
  |  |  |  | 4250|      1|    r->m_state = state_index;                                                  \
  |  |  |  | 4251|      1|    goto common_exit;                                                          \
  |  |  |  | 4252|      1|  case state_index:;                                                           \
  |  |  |  |  ------------------
  |  |  |  |  |  Branch (4252:3): [True: 0, False: 468]
  |  |  |  |  ------------------
  |  |  |  | 4253|      0|  }                                                                            \
  |  |  |  | 4254|      1|  MZ_MACRO_END
  |  |  |  |  ------------------
  |  |  |  |  |  |  726|      1|#define MZ_MACRO_END while (0)
  |  |  |  |  |  |  ------------------
  |  |  |  |  |  |  |  Branch (726:29): [Folded, False: 0]
  |  |  |  |  |  |  ------------------
  |  |  |  |  ------------------
  |  |  ------------------
  |  | 4259|      1|    }                                                                          \
  |  | 4260|      1|  }                                                                            \
  |  | 4261|      1|  MZ_MACRO_END
  |  |  ------------------
  |  |  |  |  726|      1|#define MZ_MACRO_END while (0)
  |  |  |  |  ------------------
  |  |  |  |  |  Branch (726:29): [Folded, False: 0]
  |  |  |  |  ------------------
  |  |  ------------------
  ------------------
 4607|      1|            }
 4608|  2.76k|            num_extra = "\02\03\07"[dist - 16];
 4609|  2.76k|            TINFL_GET_BITS(18, s, num_extra);
  ------------------
  |  | 4293|  2.76k|  do {                                                                         \
  |  | 4294|  2.76k|    if (num_bits < (mz_uint)(n)) {                                             \
  |  |  ------------------
  |  |  |  Branch (4294:9): [True: 3, False: 2.76k]
  |  |  ------------------
  |  | 4295|      3|      TINFL_NEED_BITS(state_index, n);                                         \
  |  |  ------------------
  |  |  |  | 4277|      3|  do {                                                                         \
  |  |  |  | 4278|      3|    mz_uint c;                                                                 \
  |  |  |  | 4279|      3|    TINFL_GET_BYTE(state_index, c);                                            \
  |  |  |  |  ------------------
  |  |  |  |  |  | 4265|      3|  do {                                                                         \
  |  |  |  |  |  | 4266|      3|    while (pIn_buf_cur >= pIn_buf_end) {                                       \
  |  |  |  |  |  |  ------------------
  |  |  |  |  |  |  |  Branch (4266:12): [True: 0, False: 3]
  |  |  |  |  |  |  ------------------
  |  |  |  |  |  | 4267|      0|      TINFL_CR_RETURN(state_index,                                             \
  |  |  |  |  |  |  ------------------
  |  |  |  |  |  |  |  | 4248|      0|  do {                                                                         \
  |  |  |  |  |  |  |  | 4249|      0|    status = result;                                                           \
  |  |  |  |  |  |  |  |  ------------------
  |  |  |  |  |  |  |  |  |  Branch (4249:14): [True: 0, False: 0]
  |  |  |  |  |  |  |  |  ------------------
  |  |  |  |  |  |  |  | 4250|      0|    r->m_state = state_index;                                                  \
  |  |  |  |  |  |  |  | 4251|      0|    goto common_exit;                                                          \
  |  |  |  |  |  |  |  | 4252|      0|  case state_index:;                                                           \
  |  |  |  |  |  |  |  |  ------------------
  |  |  |  |  |  |  |  |  |  Branch (4252:3): [True: 0, False: 468]
  |  |  |  |  |  |  |  |  ------------------
  |  |  |  |  |  |  |  | 4253|      0|  }                                                                            \
  |  |  |  |  |  |  |  | 4254|      0|  MZ_MACRO_END
  |  |  |  |  |  |  |  |  ------------------
  |  |  |  |  |  |  |  |  |  |  726|      0|#define MZ_MACRO_END while (0)
  |  |  |  |  |  |  |  |  |  |  ------------------
  |  |  |  |  |  |  |  |  |  |  |  Branch (726:29): [Folded, False: 0]
  |  |  |  |  |  |  |  |  |  |  ------------------
  |  |  |  |  |  |  |  |  ------------------
  |  |  |  |  |  |  ------------------
  |  |  |  |  |  | 4268|      0|                      (decomp_flags & TINFL_FLAG_HAS_MORE_INPUT)               \
  |  |  |  |  |  | 4269|      0|                          ? TINFL_STATUS_NEEDS_MORE_INPUT                      \
  |  |  |  |  |  | 4270|      0|                          : TINFL_STATUS_FAILED_CANNOT_MAKE_PROGRESS);         \
  |  |  |  |  |  | 4271|      0|    }                                                                          \
  |  |  |  |  |  | 4272|      3|    c = *pIn_buf_cur++;                                                        \
  |  |  |  |  |  | 4273|      3|  }                                                                            \
  |  |  |  |  |  | 4274|      3|  MZ_MACRO_END
  |  |  |  |  |  |  ------------------
  |  |  |  |  |  |  |  |  726|      3|#define MZ_MACRO_END while (0)
  |  |  |  |  |  |  |  |  ------------------
  |  |  |  |  |  |  |  |  |  Branch (726:29): [Folded, False: 3]
  |  |  |  |  |  |  |  |  ------------------
  |  |  |  |  |  |  ------------------
  |  |  |  |  ------------------
  |  |  |  | 4280|      3|    bit_buf |= (((tinfl_bit_buf_t)c) << num_bits);                             \
  |  |  |  | 4281|      3|    num_bits += 8;                                                             \
  |  |  |  | 4282|      3|  } while (num_bits < (mz_uint)(n))
  |  |  |  |  ------------------
  |  |  |  |  |  Branch (4282:12): [True: 0, False: 3]
  |  |  |  |  ------------------
  |  |  ------------------
  |  | 4296|      3|    }                                                                          \
  |  | 4297|  2.76k|    b = bit_buf & ((1 << (n)) - 1);                                            \
  |  | 4298|  2.76k|    bit_buf >>= (n);                                                           \
  |  | 4299|  2.76k|    num_bits -= (n);                                                           \
  |  | 4300|  2.76k|  }                                                                            \
  |  | 4301|  2.76k|  MZ_MACRO_END
  |  |  ------------------
  |  |  |  |  726|  2.76k|#define MZ_MACRO_END while (0)
  |  |  |  |  ------------------
  |  |  |  |  |  Branch (726:29): [Folded, False: 2.76k]
  |  |  |  |  ------------------
  |  |  ------------------
  ------------------
 4610|  2.76k|            s += "\03\03\013"[dist - 16];
 4611|  2.76k|            TINFL_MEMSET(r->m_len_codes + counter,
  ------------------
  |  | 4242|  5.53k|#define TINFL_MEMSET(p, c, l) memset(p, c, l)
  |  |  ------------------
  |  |  |  Branch (4242:41): [True: 527, False: 2.24k]
  |  |  ------------------
  ------------------
 4612|  2.76k|                         (dist == 16) ? r->m_len_codes[counter - 1] : 0, s);
 4613|  2.76k|            counter += s;
 4614|  2.76k|          }
 4615|    370|          if ((r->m_table_sizes[0] + r->m_table_sizes[1]) != counter) {
  ------------------
  |  Branch (4615:15): [True: 11, False: 359]
  ------------------
 4616|     11|            TINFL_CR_RETURN_FOREVER(21, TINFL_STATUS_FAILED);
  ------------------
  |  | 4256|     11|  do {                                                                         \
  |  | 4257|     11|    for (;;) {                                                                 \
  |  | 4258|     11|      TINFL_CR_RETURN(state_index, result);                                    \
  |  |  ------------------
  |  |  |  | 4248|     11|  do {                                                                         \
  |  |  |  | 4249|     11|    status = result;                                                           \
  |  |  |  | 4250|     11|    r->m_state = state_index;                                                  \
  |  |  |  | 4251|     11|    goto common_exit;                                                          \
  |  |  |  | 4252|     11|  case state_index:;                                                           \
  |  |  |  |  ------------------
  |  |  |  |  |  Branch (4252:3): [True: 0, False: 468]
  |  |  |  |  ------------------
  |  |  |  | 4253|      0|  }                                                                            \
  |  |  |  | 4254|     11|  MZ_MACRO_END
  |  |  |  |  ------------------
  |  |  |  |  |  |  726|     11|#define MZ_MACRO_END while (0)
  |  |  |  |  |  |  ------------------
  |  |  |  |  |  |  |  Branch (726:29): [Folded, False: 0]
  |  |  |  |  |  |  ------------------
  |  |  |  |  ------------------
  |  |  ------------------
  |  | 4259|     11|    }                                                                          \
  |  | 4260|     11|  }                                                                            \
  |  | 4261|     11|  MZ_MACRO_END
  |  |  ------------------
  |  |  |  |  726|     11|#define MZ_MACRO_END while (0)
  |  |  |  |  ------------------
  |  |  |  |  |  Branch (726:29): [Folded, False: 0]
  |  |  |  |  ------------------
  |  |  ------------------
  ------------------
 4617|     11|          }
 4618|    359|          TINFL_MEMCPY(r->m_code_size_0, r->m_len_codes, r->m_table_sizes[0]);
  ------------------
  |  | 4241|    359|#define TINFL_MEMCPY(d, s, l) memcpy(d, s, l)
  ------------------
 4619|    359|          TINFL_MEMCPY(r->m_code_size_1, r->m_len_codes + r->m_table_sizes[0],
  ------------------
  |  | 4241|    359|#define TINFL_MEMCPY(d, s, l) memcpy(d, s, l)
  ------------------
 4620|    359|                       r->m_table_sizes[1]);
 4621|    359|        }
 4622|  3.16k|      }
 4623|  5.44k|      for (;;) {
 4624|  5.44k|        mz_uint8 *pSrc;
 4625|   153k|        for (;;) {
 4626|   153k|          if (((pIn_buf_end - pIn_buf_cur) < 4) ||
  ------------------
  |  Branch (4626:15): [True: 6.55k, False: 146k]
  ------------------
 4627|   146k|              ((pOut_buf_end - pOut_buf_cur) < 2)) {
  ------------------
  |  Branch (4627:15): [True: 434, False: 146k]
  ------------------
 4628|  6.98k|            TINFL_HUFF_DECODE(23, counter, r->m_look_up[0], r->m_tree_0);
  ------------------
  |  | 4348|  6.98k|  do {                                                                         \
  |  | 4349|  6.98k|    int temp;                                                                  \
  |  | 4350|  6.98k|    mz_uint code_len, c;                                                       \
  |  | 4351|  6.98k|    if (num_bits < 15) {                                                       \
  |  |  ------------------
  |  |  |  Branch (4351:9): [True: 464, False: 6.52k]
  |  |  ------------------
  |  | 4352|    464|      if ((pIn_buf_end - pIn_buf_cur) < 2) {                                   \
  |  |  ------------------
  |  |  |  Branch (4352:11): [True: 265, False: 199]
  |  |  ------------------
  |  | 4353|    265|        TINFL_HUFF_BITBUF_FILL(state_index, pLookUp, pTree);                   \
  |  |  ------------------
  |  |  |  | 4313|    309|  do {                                                                         \
  |  |  |  | 4314|    309|    temp = pLookUp[bit_buf & (TINFL_FAST_LOOKUP_SIZE - 1)];                    \
  |  |  |  | 4315|    309|    if (temp >= 0) {                                                           \
  |  |  |  |  ------------------
  |  |  |  |  |  Branch (4315:9): [True: 230, False: 79]
  |  |  |  |  ------------------
  |  |  |  | 4316|    230|      code_len = temp >> 9;                                                    \
  |  |  |  | 4317|    230|      if ((code_len) && (num_bits >= code_len))                                \
  |  |  |  |  ------------------
  |  |  |  |  |  Branch (4317:11): [True: 197, False: 33]
  |  |  |  |  |  Branch (4317:25): [True: 168, False: 29]
  |  |  |  |  ------------------
  |  |  |  | 4318|    230|        break;                                                                 \
  |  |  |  | 4319|    230|    } else if (num_bits > TINFL_FAST_LOOKUP_BITS) {                            \
  |  |  |  |  ------------------
  |  |  |  |  |  Branch (4319:16): [True: 34, False: 45]
  |  |  |  |  ------------------
  |  |  |  | 4320|     34|      code_len = TINFL_FAST_LOOKUP_BITS;                                       \
  |  |  |  | 4321|     64|      do {                                                                     \
  |  |  |  | 4322|     64|        temp = pTree[~temp + ((bit_buf >> code_len++) & 1)];                   \
  |  |  |  | 4323|     64|      } while ((temp < 0) && (num_bits >= (code_len + 1)));                    \
  |  |  |  |  ------------------
  |  |  |  |  |  Branch (4323:16): [True: 41, False: 23]
  |  |  |  |  |  Branch (4323:30): [True: 30, False: 11]
  |  |  |  |  ------------------
  |  |  |  | 4324|     34|      if (temp >= 0)                                                           \
  |  |  |  |  ------------------
  |  |  |  |  |  Branch (4324:11): [True: 23, False: 11]
  |  |  |  |  ------------------
  |  |  |  | 4325|     34|        break;                                                                 \
  |  |  |  | 4326|     34|    }                                                                          \
  |  |  |  | 4327|    309|    TINFL_GET_BYTE(state_index, c);                                            \
  |  |  |  |  ------------------
  |  |  |  |  |  | 4265|    118|  do {                                                                         \
  |  |  |  |  |  | 4266|    118|    while (pIn_buf_cur >= pIn_buf_end) {                                       \
  |  |  |  |  |  |  ------------------
  |  |  |  |  |  |  |  Branch (4266:12): [True: 57, False: 61]
  |  |  |  |  |  |  ------------------
  |  |  |  |  |  | 4267|     57|      TINFL_CR_RETURN(state_index,                                             \
  |  |  |  |  |  |  ------------------
  |  |  |  |  |  |  |  | 4248|     57|  do {                                                                         \
  |  |  |  |  |  |  |  | 4249|    114|    status = result;                                                           \
  |  |  |  |  |  |  |  |  ------------------
  |  |  |  |  |  |  |  |  |  Branch (4249:14): [True: 0, False: 57]
  |  |  |  |  |  |  |  |  ------------------
  |  |  |  |  |  |  |  | 4250|     57|    r->m_state = state_index;                                                  \
  |  |  |  |  |  |  |  | 4251|     57|    goto common_exit;                                                          \
  |  |  |  |  |  |  |  | 4252|     57|  case state_index:;                                                           \
  |  |  |  |  |  |  |  |  ------------------
  |  |  |  |  |  |  |  |  |  Branch (4252:3): [True: 0, False: 468]
  |  |  |  |  |  |  |  |  ------------------
  |  |  |  |  |  |  |  | 4253|      0|  }                                                                            \
  |  |  |  |  |  |  |  | 4254|     57|  MZ_MACRO_END
  |  |  |  |  |  |  |  |  ------------------
  |  |  |  |  |  |  |  |  |  |  726|     57|#define MZ_MACRO_END while (0)
  |  |  |  |  |  |  |  |  |  |  ------------------
  |  |  |  |  |  |  |  |  |  |  |  Branch (726:29): [Folded, False: 0]
  |  |  |  |  |  |  |  |  |  |  ------------------
  |  |  |  |  |  |  |  |  ------------------
  |  |  |  |  |  |  ------------------
  |  |  |  |  |  | 4268|     57|                      (decomp_flags & TINFL_FLAG_HAS_MORE_INPUT)               \
  |  |  |  |  |  | 4269|     57|                          ? TINFL_STATUS_NEEDS_MORE_INPUT                      \
  |  |  |  |  |  | 4270|     57|                          : TINFL_STATUS_FAILED_CANNOT_MAKE_PROGRESS);         \
  |  |  |  |  |  | 4271|     57|    }                                                                          \
  |  |  |  |  |  | 4272|    118|    c = *pIn_buf_cur++;                                                        \
  |  |  |  |  |  | 4273|     61|  }                                                                            \
  |  |  |  |  |  | 4274|    309|  MZ_MACRO_END
  |  |  |  |  |  |  ------------------
  |  |  |  |  |  |  |  |  726|    309|#define MZ_MACRO_END while (0)
  |  |  |  |  |  |  |  |  ------------------
  |  |  |  |  |  |  |  |  |  Branch (726:29): [Folded, False: 61]
  |  |  |  |  |  |  |  |  ------------------
  |  |  |  |  |  |  ------------------
  |  |  |  |  ------------------
  |  |  |  | 4328|    118|    bit_buf |= (((tinfl_bit_buf_t)c) << num_bits);                             \
  |  |  |  | 4329|     61|    num_bits += 8;                                                             \
  |  |  |  | 4330|     61|  } while (num_bits < 15);
  |  |  |  |  ------------------
  |  |  |  |  |  Branch (4330:12): [True: 44, False: 17]
  |  |  |  |  ------------------
  |  |  ------------------
  |  | 4354|    208|      } else {                                                                 \
  |  | 4355|    199|        bit_buf |= (((tinfl_bit_buf_t)pIn_buf_cur[0]) << num_bits) |           \
  |  | 4356|    199|                   (((tinfl_bit_buf_t)pIn_buf_cur[1]) << (num_bits + 8));      \
  |  | 4357|    199|        pIn_buf_cur += 2;                                                      \
  |  | 4358|    199|        num_bits += 16;                                                        \
  |  | 4359|    199|      }                                                                        \
  |  | 4360|    464|    }                                                                          \
  |  | 4361|  6.98k|    if ((temp = pLookUp[bit_buf & (TINFL_FAST_LOOKUP_SIZE - 1)]) >= 0)         \
  |  |  ------------------
  |  |  |  Branch (4361:9): [True: 6.81k, False: 117]
  |  |  ------------------
  |  | 4362|  6.92k|      code_len = temp >> 9, temp &= 511;                                       \
  |  | 4363|  6.92k|    else {                                                                     \
  |  | 4364|    117|      code_len = TINFL_FAST_LOOKUP_BITS;                                       \
  |  | 4365|    271|      do {                                                                     \
  |  | 4366|    271|        temp = pTree[~temp + ((bit_buf >> code_len++) & 1)];                   \
  |  | 4367|    271|      } while (temp < 0);                                                      \
  |  |  ------------------
  |  |  |  Branch (4367:16): [True: 154, False: 117]
  |  |  ------------------
  |  | 4368|    117|    }                                                                          \
  |  | 4369|  6.92k|    sym = temp;                                                                \
  |  | 4370|  6.92k|    bit_buf >>= code_len;                                                      \
  |  | 4371|  6.92k|    num_bits -= code_len;                                                      \
  |  | 4372|  6.92k|  }                                                                            \
  |  | 4373|  6.98k|  MZ_MACRO_END
  |  |  ------------------
  |  |  |  |  726|  6.98k|#define MZ_MACRO_END while (0)
  |  |  |  |  ------------------
  |  |  |  |  |  Branch (726:29): [Folded, False: 6.92k]
  |  |  |  |  ------------------
  |  |  ------------------
  ------------------
 4629|  6.92k|            if (counter >= 256)
  ------------------
  |  Branch (4629:17): [True: 564, False: 6.36k]
  ------------------
 4630|    564|              break;
 4631|  6.36k|            while (pOut_buf_cur >= pOut_buf_end) {
  ------------------
  |  Branch (4631:20): [True: 99, False: 6.26k]
  ------------------
 4632|     99|              TINFL_CR_RETURN(24, TINFL_STATUS_HAS_MORE_OUTPUT);
  ------------------
  |  | 4248|     99|  do {                                                                         \
  |  | 4249|     99|    status = result;                                                           \
  |  | 4250|     99|    r->m_state = state_index;                                                  \
  |  | 4251|     99|    goto common_exit;                                                          \
  |  | 4252|     99|  case state_index:;                                                           \
  |  |  ------------------
  |  |  |  Branch (4252:3): [True: 0, False: 468]
  |  |  ------------------
  |  | 4253|      0|  }                                                                            \
  |  | 4254|     99|  MZ_MACRO_END
  |  |  ------------------
  |  |  |  |  726|     99|#define MZ_MACRO_END while (0)
  |  |  |  |  ------------------
  |  |  |  |  |  Branch (726:29): [Folded, False: 0]
  |  |  |  |  ------------------
  |  |  ------------------
  ------------------
 4633|     99|            }
 4634|  6.26k|            *pOut_buf_cur++ = (mz_uint8)counter;
 4635|   146k|          } else {
 4636|   146k|            int sym2;
 4637|   146k|            mz_uint code_len;
 4638|   146k|#if TINFL_USE_64BIT_BITBUF
 4639|   146k|            if (num_bits < 30) {
  ------------------
  |  Branch (4639:17): [True: 9.65k, False: 136k]
  ------------------
 4640|  9.65k|              bit_buf |=
 4641|  9.65k|                  (((tinfl_bit_buf_t)MZ_READ_LE32(pIn_buf_cur)) << num_bits);
  ------------------
  |  |  772|  9.65k|  ((mz_uint32)(((const mz_uint8 *)(p))[0]) |                                   \
  |  |  773|  9.65k|   ((mz_uint32)(((const mz_uint8 *)(p))[1]) << 8U) |                           \
  |  |  774|  9.65k|   ((mz_uint32)(((const mz_uint8 *)(p))[2]) << 16U) |                          \
  |  |  775|  9.65k|   ((mz_uint32)(((const mz_uint8 *)(p))[3]) << 24U))
  ------------------
 4642|  9.65k|              pIn_buf_cur += 4;
 4643|  9.65k|              num_bits += 32;
 4644|  9.65k|            }
 4645|       |#else
 4646|       |            if (num_bits < 15) {
 4647|       |              bit_buf |=
 4648|       |                  (((tinfl_bit_buf_t)MZ_READ_LE16(pIn_buf_cur)) << num_bits);
 4649|       |              pIn_buf_cur += 2;
 4650|       |              num_bits += 16;
 4651|       |            }
 4652|       |#endif
 4653|   146k|            if ((sym2 =
  ------------------
  |  Branch (4653:17): [True: 145k, False: 882]
  ------------------
 4654|   146k|                     r->m_look_up[0][bit_buf & (TINFL_FAST_LOOKUP_SIZE - 1)]) >=
 4655|   146k|                0)
 4656|   145k|              code_len = sym2 >> 9;
 4657|    882|            else {
 4658|    882|              code_len = TINFL_FAST_LOOKUP_BITS;
 4659|  3.82k|              do {
 4660|  3.82k|                sym2 = r->m_tree_0[~sym2 + ((bit_buf >> code_len++) & 1)];
 4661|  3.82k|              } while (sym2 < 0);
  ------------------
  |  Branch (4661:24): [True: 2.94k, False: 882]
  ------------------
 4662|    882|            }
 4663|   146k|            counter = sym2;
 4664|   146k|            bit_buf >>= code_len;
 4665|   146k|            num_bits -= code_len;
 4666|   146k|            if (counter & 256)
  ------------------
  |  Branch (4666:17): [True: 3.60k, False: 142k]
  ------------------
 4667|  3.60k|              break;
 4668|       |
 4669|       |#if !TINFL_USE_64BIT_BITBUF
 4670|       |            if (num_bits < 15) {
 4671|       |              bit_buf |=
 4672|       |                  (((tinfl_bit_buf_t)MZ_READ_LE16(pIn_buf_cur)) << num_bits);
 4673|       |              pIn_buf_cur += 2;
 4674|       |              num_bits += 16;
 4675|       |            }
 4676|       |#endif
 4677|   142k|            if ((sym2 =
  ------------------
  |  Branch (4677:17): [True: 142k, False: 157]
  ------------------
 4678|   142k|                     r->m_look_up[0][bit_buf & (TINFL_FAST_LOOKUP_SIZE - 1)]) >=
 4679|   142k|                0)
 4680|   142k|              code_len = sym2 >> 9;
 4681|    157|            else {
 4682|    157|              code_len = TINFL_FAST_LOOKUP_BITS;
 4683|    230|              do {
 4684|    230|                sym2 = r->m_tree_0[~sym2 + ((bit_buf >> code_len++) & 1)];
 4685|    230|              } while (sym2 < 0);
  ------------------
  |  Branch (4685:24): [True: 73, False: 157]
  ------------------
 4686|    157|            }
 4687|   142k|            bit_buf >>= code_len;
 4688|   142k|            num_bits -= code_len;
 4689|       |
 4690|   142k|            pOut_buf_cur[0] = (mz_uint8)counter;
 4691|   142k|            if (sym2 & 256) {
  ------------------
  |  Branch (4691:17): [True: 1.11k, False: 141k]
  ------------------
 4692|  1.11k|              pOut_buf_cur++;
 4693|  1.11k|              counter = sym2;
 4694|  1.11k|              break;
 4695|  1.11k|            }
 4696|   141k|            pOut_buf_cur[1] = (mz_uint8)sym2;
 4697|   141k|            pOut_buf_cur += 2;
 4698|   141k|          }
 4699|   153k|        }
 4700|  5.29k|        if ((counter &= 511) == 256)
  ------------------
  |  Branch (4700:13): [True: 1.12k, False: 4.16k]
  ------------------
 4701|  1.12k|          break;
 4702|       |
 4703|  4.16k|        num_extra = s_length_extra[counter - 257];
 4704|  4.16k|        counter = s_length_base[counter - 257];
 4705|  4.16k|        if (num_extra) {
  ------------------
  |  Branch (4705:13): [True: 1.81k, False: 2.35k]
  ------------------
 4706|  1.81k|          mz_uint extra_bits;
 4707|  1.81k|          TINFL_GET_BITS(25, extra_bits, num_extra);
  ------------------
  |  | 4293|  1.81k|  do {                                                                         \
  |  | 4294|  1.81k|    if (num_bits < (mz_uint)(n)) {                                             \
  |  |  ------------------
  |  |  |  Branch (4294:9): [True: 1, False: 1.81k]
  |  |  ------------------
  |  | 4295|      1|      TINFL_NEED_BITS(state_index, n);                                         \
  |  |  ------------------
  |  |  |  | 4277|      1|  do {                                                                         \
  |  |  |  | 4278|      1|    mz_uint c;                                                                 \
  |  |  |  | 4279|      1|    TINFL_GET_BYTE(state_index, c);                                            \
  |  |  |  |  ------------------
  |  |  |  |  |  | 4265|      1|  do {                                                                         \
  |  |  |  |  |  | 4266|      1|    while (pIn_buf_cur >= pIn_buf_end) {                                       \
  |  |  |  |  |  |  ------------------
  |  |  |  |  |  |  |  Branch (4266:12): [True: 0, False: 1]
  |  |  |  |  |  |  ------------------
  |  |  |  |  |  | 4267|      0|      TINFL_CR_RETURN(state_index,                                             \
  |  |  |  |  |  |  ------------------
  |  |  |  |  |  |  |  | 4248|      0|  do {                                                                         \
  |  |  |  |  |  |  |  | 4249|      0|    status = result;                                                           \
  |  |  |  |  |  |  |  |  ------------------
  |  |  |  |  |  |  |  |  |  Branch (4249:14): [True: 0, False: 0]
  |  |  |  |  |  |  |  |  ------------------
  |  |  |  |  |  |  |  | 4250|      0|    r->m_state = state_index;                                                  \
  |  |  |  |  |  |  |  | 4251|      0|    goto common_exit;                                                          \
  |  |  |  |  |  |  |  | 4252|      0|  case state_index:;                                                           \
  |  |  |  |  |  |  |  |  ------------------
  |  |  |  |  |  |  |  |  |  Branch (4252:3): [True: 0, False: 468]
  |  |  |  |  |  |  |  |  ------------------
  |  |  |  |  |  |  |  | 4253|      0|  }                                                                            \
  |  |  |  |  |  |  |  | 4254|      0|  MZ_MACRO_END
  |  |  |  |  |  |  |  |  ------------------
  |  |  |  |  |  |  |  |  |  |  726|      0|#define MZ_MACRO_END while (0)
  |  |  |  |  |  |  |  |  |  |  ------------------
  |  |  |  |  |  |  |  |  |  |  |  Branch (726:29): [Folded, False: 0]
  |  |  |  |  |  |  |  |  |  |  ------------------
  |  |  |  |  |  |  |  |  ------------------
  |  |  |  |  |  |  ------------------
  |  |  |  |  |  | 4268|      0|                      (decomp_flags & TINFL_FLAG_HAS_MORE_INPUT)               \
  |  |  |  |  |  | 4269|      0|                          ? TINFL_STATUS_NEEDS_MORE_INPUT                      \
  |  |  |  |  |  | 4270|      0|                          : TINFL_STATUS_FAILED_CANNOT_MAKE_PROGRESS);         \
  |  |  |  |  |  | 4271|      0|    }                                                                          \
  |  |  |  |  |  | 4272|      1|    c = *pIn_buf_cur++;                                                        \
  |  |  |  |  |  | 4273|      1|  }                                                                            \
  |  |  |  |  |  | 4274|      1|  MZ_MACRO_END
  |  |  |  |  |  |  ------------------
  |  |  |  |  |  |  |  |  726|      1|#define MZ_MACRO_END while (0)
  |  |  |  |  |  |  |  |  ------------------
  |  |  |  |  |  |  |  |  |  Branch (726:29): [Folded, False: 1]
  |  |  |  |  |  |  |  |  ------------------
  |  |  |  |  |  |  ------------------
  |  |  |  |  ------------------
  |  |  |  | 4280|      1|    bit_buf |= (((tinfl_bit_buf_t)c) << num_bits);                             \
  |  |  |  | 4281|      1|    num_bits += 8;                                                             \
  |  |  |  | 4282|      1|  } while (num_bits < (mz_uint)(n))
  |  |  |  |  ------------------
  |  |  |  |  |  Branch (4282:12): [True: 0, False: 1]
  |  |  |  |  ------------------
  |  |  ------------------
  |  | 4296|      1|    }                                                                          \
  |  | 4297|  1.81k|    b = bit_buf & ((1 << (n)) - 1);                                            \
  |  | 4298|  1.81k|    bit_buf >>= (n);                                                           \
  |  | 4299|  1.81k|    num_bits -= (n);                                                           \
  |  | 4300|  1.81k|  }                                                                            \
  |  | 4301|  1.81k|  MZ_MACRO_END
  |  |  ------------------
  |  |  |  |  726|  1.81k|#define MZ_MACRO_END while (0)
  |  |  |  |  ------------------
  |  |  |  |  |  Branch (726:29): [Folded, False: 1.81k]
  |  |  |  |  ------------------
  |  |  ------------------
  ------------------
 4708|  1.81k|          counter += extra_bits;
 4709|  1.81k|        }
 4710|       |
 4711|  4.16k|        TINFL_HUFF_DECODE(26, dist, r->m_look_up[1], r->m_tree_1);
  ------------------
  |  | 4348|  4.16k|  do {                                                                         \
  |  | 4349|  4.16k|    int temp;                                                                  \
  |  | 4350|  4.16k|    mz_uint code_len, c;                                                       \
  |  | 4351|  4.16k|    if (num_bits < 15) {                                                       \
  |  |  ------------------
  |  |  |  Branch (4351:9): [True: 337, False: 3.83k]
  |  |  ------------------
  |  | 4352|    337|      if ((pIn_buf_end - pIn_buf_cur) < 2) {                                   \
  |  |  ------------------
  |  |  |  Branch (4352:11): [True: 108, False: 229]
  |  |  ------------------
  |  | 4353|    108|        TINFL_HUFF_BITBUF_FILL(state_index, pLookUp, pTree);                   \
  |  |  ------------------
  |  |  |  | 4313|    122|  do {                                                                         \
  |  |  |  | 4314|    122|    temp = pLookUp[bit_buf & (TINFL_FAST_LOOKUP_SIZE - 1)];                    \
  |  |  |  | 4315|    122|    if (temp >= 0) {                                                           \
  |  |  |  |  ------------------
  |  |  |  |  |  Branch (4315:9): [True: 61, False: 61]
  |  |  |  |  ------------------
  |  |  |  | 4316|     61|      code_len = temp >> 9;                                                    \
  |  |  |  | 4317|     61|      if ((code_len) && (num_bits >= code_len))                                \
  |  |  |  |  ------------------
  |  |  |  |  |  Branch (4317:11): [True: 43, False: 18]
  |  |  |  |  |  Branch (4317:25): [True: 39, False: 4]
  |  |  |  |  ------------------
  |  |  |  | 4318|     61|        break;                                                                 \
  |  |  |  | 4319|     61|    } else if (num_bits > TINFL_FAST_LOOKUP_BITS) {                            \
  |  |  |  |  ------------------
  |  |  |  |  |  Branch (4319:16): [True: 28, False: 33]
  |  |  |  |  ------------------
  |  |  |  | 4320|     28|      code_len = TINFL_FAST_LOOKUP_BITS;                                       \
  |  |  |  | 4321|     63|      do {                                                                     \
  |  |  |  | 4322|     63|        temp = pTree[~temp + ((bit_buf >> code_len++) & 1)];                   \
  |  |  |  | 4323|     63|      } while ((temp < 0) && (num_bits >= (code_len + 1)));                    \
  |  |  |  |  ------------------
  |  |  |  |  |  Branch (4323:16): [True: 53, False: 10]
  |  |  |  |  |  Branch (4323:30): [True: 35, False: 18]
  |  |  |  |  ------------------
  |  |  |  | 4324|     28|      if (temp >= 0)                                                           \
  |  |  |  |  ------------------
  |  |  |  |  |  Branch (4324:11): [True: 10, False: 18]
  |  |  |  |  ------------------
  |  |  |  | 4325|     28|        break;                                                                 \
  |  |  |  | 4326|     28|    }                                                                          \
  |  |  |  | 4327|    122|    TINFL_GET_BYTE(state_index, c);                                            \
  |  |  |  |  ------------------
  |  |  |  |  |  | 4265|     73|  do {                                                                         \
  |  |  |  |  |  | 4266|     73|    while (pIn_buf_cur >= pIn_buf_end) {                                       \
  |  |  |  |  |  |  ------------------
  |  |  |  |  |  |  |  Branch (4266:12): [True: 34, False: 39]
  |  |  |  |  |  |  ------------------
  |  |  |  |  |  | 4267|     34|      TINFL_CR_RETURN(state_index,                                             \
  |  |  |  |  |  |  ------------------
  |  |  |  |  |  |  |  | 4248|     34|  do {                                                                         \
  |  |  |  |  |  |  |  | 4249|     68|    status = result;                                                           \
  |  |  |  |  |  |  |  |  ------------------
  |  |  |  |  |  |  |  |  |  Branch (4249:14): [True: 0, False: 34]
  |  |  |  |  |  |  |  |  ------------------
  |  |  |  |  |  |  |  | 4250|     34|    r->m_state = state_index;                                                  \
  |  |  |  |  |  |  |  | 4251|     34|    goto common_exit;                                                          \
  |  |  |  |  |  |  |  | 4252|     34|  case state_index:;                                                           \
  |  |  |  |  |  |  |  |  ------------------
  |  |  |  |  |  |  |  |  |  Branch (4252:3): [True: 0, False: 468]
  |  |  |  |  |  |  |  |  ------------------
  |  |  |  |  |  |  |  | 4253|      0|  }                                                                            \
  |  |  |  |  |  |  |  | 4254|     34|  MZ_MACRO_END
  |  |  |  |  |  |  |  |  ------------------
  |  |  |  |  |  |  |  |  |  |  726|     34|#define MZ_MACRO_END while (0)
  |  |  |  |  |  |  |  |  |  |  ------------------
  |  |  |  |  |  |  |  |  |  |  |  Branch (726:29): [Folded, False: 0]
  |  |  |  |  |  |  |  |  |  |  ------------------
  |  |  |  |  |  |  |  |  ------------------
  |  |  |  |  |  |  ------------------
  |  |  |  |  |  | 4268|     34|                      (decomp_flags & TINFL_FLAG_HAS_MORE_INPUT)               \
  |  |  |  |  |  | 4269|     34|                          ? TINFL_STATUS_NEEDS_MORE_INPUT                      \
  |  |  |  |  |  | 4270|     34|                          : TINFL_STATUS_FAILED_CANNOT_MAKE_PROGRESS);         \
  |  |  |  |  |  | 4271|     34|    }                                                                          \
  |  |  |  |  |  | 4272|     73|    c = *pIn_buf_cur++;                                                        \
  |  |  |  |  |  | 4273|     39|  }                                                                            \
  |  |  |  |  |  | 4274|    122|  MZ_MACRO_END
  |  |  |  |  |  |  ------------------
  |  |  |  |  |  |  |  |  726|    122|#define MZ_MACRO_END while (0)
  |  |  |  |  |  |  |  |  ------------------
  |  |  |  |  |  |  |  |  |  Branch (726:29): [Folded, False: 39]
  |  |  |  |  |  |  |  |  ------------------
  |  |  |  |  |  |  ------------------
  |  |  |  |  ------------------
  |  |  |  | 4328|     73|    bit_buf |= (((tinfl_bit_buf_t)c) << num_bits);                             \
  |  |  |  | 4329|     39|    num_bits += 8;                                                             \
  |  |  |  | 4330|     39|  } while (num_bits < 15);
  |  |  |  |  ------------------
  |  |  |  |  |  Branch (4330:12): [True: 14, False: 25]
  |  |  |  |  ------------------
  |  |  ------------------
  |  | 4354|    229|      } else {                                                                 \
  |  | 4355|    229|        bit_buf |= (((tinfl_bit_buf_t)pIn_buf_cur[0]) << num_bits) |           \
  |  | 4356|    229|                   (((tinfl_bit_buf_t)pIn_buf_cur[1]) << (num_bits + 8));      \
  |  | 4357|    229|        pIn_buf_cur += 2;                                                      \
  |  | 4358|    229|        num_bits += 16;                                                        \
  |  | 4359|    229|      }                                                                        \
  |  | 4360|    337|    }                                                                          \
  |  | 4361|  4.16k|    if ((temp = pLookUp[bit_buf & (TINFL_FAST_LOOKUP_SIZE - 1)]) >= 0)         \
  |  |  ------------------
  |  |  |  Branch (4361:9): [True: 3.42k, False: 707]
  |  |  ------------------
  |  | 4362|  4.13k|      code_len = temp >> 9, temp &= 511;                                       \
  |  | 4363|  4.13k|    else {                                                                     \
  |  | 4364|    707|      code_len = TINFL_FAST_LOOKUP_BITS;                                       \
  |  | 4365|  3.46k|      do {                                                                     \
  |  | 4366|  3.46k|        temp = pTree[~temp + ((bit_buf >> code_len++) & 1)];                   \
  |  | 4367|  3.46k|      } while (temp < 0);                                                      \
  |  |  ------------------
  |  |  |  Branch (4367:16): [True: 2.76k, False: 707]
  |  |  ------------------
  |  | 4368|    707|    }                                                                          \
  |  | 4369|  4.13k|    sym = temp;                                                                \
  |  | 4370|  4.13k|    bit_buf >>= code_len;                                                      \
  |  | 4371|  4.13k|    num_bits -= code_len;                                                      \
  |  | 4372|  4.13k|  }                                                                            \
  |  | 4373|  4.16k|  MZ_MACRO_END
  |  |  ------------------
  |  |  |  |  726|  4.16k|#define MZ_MACRO_END while (0)
  |  |  |  |  ------------------
  |  |  |  |  |  Branch (726:29): [Folded, False: 4.13k]
  |  |  |  |  ------------------
  |  |  ------------------
  ------------------
 4712|  4.13k|        num_extra = s_dist_extra[dist];
 4713|  4.13k|        dist = s_dist_base[dist];
 4714|  4.13k|        if (num_extra) {
  ------------------
  |  Branch (4714:13): [True: 2.30k, False: 1.82k]
  ------------------
 4715|  2.30k|          mz_uint extra_bits;
 4716|  2.30k|          TINFL_GET_BITS(27, extra_bits, num_extra);
  ------------------
  |  | 4293|  2.30k|  do {                                                                         \
  |  | 4294|  2.30k|    if (num_bits < (mz_uint)(n)) {                                             \
  |  |  ------------------
  |  |  |  Branch (4294:9): [True: 164, False: 2.14k]
  |  |  ------------------
  |  | 4295|    164|      TINFL_NEED_BITS(state_index, n);                                         \
  |  |  ------------------
  |  |  |  | 4277|    165|  do {                                                                         \
  |  |  |  | 4278|    165|    mz_uint c;                                                                 \
  |  |  |  | 4279|    165|    TINFL_GET_BYTE(state_index, c);                                            \
  |  |  |  |  ------------------
  |  |  |  |  |  | 4265|    165|  do {                                                                         \
  |  |  |  |  |  | 4266|    165|    while (pIn_buf_cur >= pIn_buf_end) {                                       \
  |  |  |  |  |  |  ------------------
  |  |  |  |  |  |  |  Branch (4266:12): [True: 13, False: 152]
  |  |  |  |  |  |  ------------------
  |  |  |  |  |  | 4267|     13|      TINFL_CR_RETURN(state_index,                                             \
  |  |  |  |  |  |  ------------------
  |  |  |  |  |  |  |  | 4248|     13|  do {                                                                         \
  |  |  |  |  |  |  |  | 4249|     26|    status = result;                                                           \
  |  |  |  |  |  |  |  |  ------------------
  |  |  |  |  |  |  |  |  |  Branch (4249:14): [True: 0, False: 13]
  |  |  |  |  |  |  |  |  ------------------
  |  |  |  |  |  |  |  | 4250|     13|    r->m_state = state_index;                                                  \
  |  |  |  |  |  |  |  | 4251|     13|    goto common_exit;                                                          \
  |  |  |  |  |  |  |  | 4252|     13|  case state_index:;                                                           \
  |  |  |  |  |  |  |  |  ------------------
  |  |  |  |  |  |  |  |  |  Branch (4252:3): [True: 0, False: 468]
  |  |  |  |  |  |  |  |  ------------------
  |  |  |  |  |  |  |  | 4253|      0|  }                                                                            \
  |  |  |  |  |  |  |  | 4254|     13|  MZ_MACRO_END
  |  |  |  |  |  |  |  |  ------------------
  |  |  |  |  |  |  |  |  |  |  726|     13|#define MZ_MACRO_END while (0)
  |  |  |  |  |  |  |  |  |  |  ------------------
  |  |  |  |  |  |  |  |  |  |  |  Branch (726:29): [Folded, False: 0]
  |  |  |  |  |  |  |  |  |  |  ------------------
  |  |  |  |  |  |  |  |  ------------------
  |  |  |  |  |  |  ------------------
  |  |  |  |  |  | 4268|     13|                      (decomp_flags & TINFL_FLAG_HAS_MORE_INPUT)               \
  |  |  |  |  |  | 4269|     13|                          ? TINFL_STATUS_NEEDS_MORE_INPUT                      \
  |  |  |  |  |  | 4270|     13|                          : TINFL_STATUS_FAILED_CANNOT_MAKE_PROGRESS);         \
  |  |  |  |  |  | 4271|     13|    }                                                                          \
  |  |  |  |  |  | 4272|    165|    c = *pIn_buf_cur++;                                                        \
  |  |  |  |  |  | 4273|    152|  }                                                                            \
  |  |  |  |  |  | 4274|    165|  MZ_MACRO_END
  |  |  |  |  |  |  ------------------
  |  |  |  |  |  |  |  |  726|    165|#define MZ_MACRO_END while (0)
  |  |  |  |  |  |  |  |  ------------------
  |  |  |  |  |  |  |  |  |  Branch (726:29): [Folded, False: 152]
  |  |  |  |  |  |  |  |  ------------------
  |  |  |  |  |  |  ------------------
  |  |  |  |  ------------------
  |  |  |  | 4280|    165|    bit_buf |= (((tinfl_bit_buf_t)c) << num_bits);                             \
  |  |  |  | 4281|    152|    num_bits += 8;                                                             \
  |  |  |  | 4282|    152|  } while (num_bits < (mz_uint)(n))
  |  |  |  |  ------------------
  |  |  |  |  |  Branch (4282:12): [True: 1, False: 151]
  |  |  |  |  ------------------
  |  |  ------------------
  |  | 4296|    164|    }                                                                          \
  |  | 4297|  2.30k|    b = bit_buf & ((1 << (n)) - 1);                                            \
  |  | 4298|  2.29k|    bit_buf >>= (n);                                                           \
  |  | 4299|  2.29k|    num_bits -= (n);                                                           \
  |  | 4300|  2.29k|  }                                                                            \
  |  | 4301|  2.30k|  MZ_MACRO_END
  |  |  ------------------
  |  |  |  |  726|  2.30k|#define MZ_MACRO_END while (0)
  |  |  |  |  ------------------
  |  |  |  |  |  Branch (726:29): [Folded, False: 2.29k]
  |  |  |  |  ------------------
  |  |  ------------------
  ------------------
 4717|  2.29k|          dist += extra_bits;
 4718|  2.29k|        }
 4719|       |
 4720|  4.12k|        dist_from_out_buf_start = pOut_buf_cur - pOut_buf_start;
 4721|  4.12k|        if ((dist == 0 || dist > dist_from_out_buf_start ||
  ------------------
  |  Branch (4721:14): [True: 8, False: 4.11k]
  |  Branch (4721:27): [True: 15, False: 4.09k]
  ------------------
 4722|  4.09k|             dist_from_out_buf_start == 0) &&
  ------------------
  |  Branch (4722:14): [True: 0, False: 4.09k]
  ------------------
 4723|     23|            (decomp_flags & TINFL_FLAG_USING_NON_WRAPPING_OUTPUT_BUF)) {
  ------------------
  |  Branch (4723:13): [True: 23, False: 0]
  ------------------
 4724|     23|          TINFL_CR_RETURN_FOREVER(37, TINFL_STATUS_FAILED);
  ------------------
  |  | 4256|     23|  do {                                                                         \
  |  | 4257|     23|    for (;;) {                                                                 \
  |  | 4258|     23|      TINFL_CR_RETURN(state_index, result);                                    \
  |  |  ------------------
  |  |  |  | 4248|     23|  do {                                                                         \
  |  |  |  | 4249|     23|    status = result;                                                           \
  |  |  |  | 4250|     23|    r->m_state = state_index;                                                  \
  |  |  |  | 4251|     23|    goto common_exit;                                                          \
  |  |  |  | 4252|     23|  case state_index:;                                                           \
  |  |  |  |  ------------------
  |  |  |  |  |  Branch (4252:3): [True: 0, False: 468]
  |  |  |  |  ------------------
  |  |  |  | 4253|      0|  }                                                                            \
  |  |  |  | 4254|     23|  MZ_MACRO_END
  |  |  |  |  ------------------
  |  |  |  |  |  |  726|     23|#define MZ_MACRO_END while (0)
  |  |  |  |  |  |  ------------------
  |  |  |  |  |  |  |  Branch (726:29): [Folded, False: 0]
  |  |  |  |  |  |  ------------------
  |  |  |  |  ------------------
  |  |  ------------------
  |  | 4259|     23|    }                                                                          \
  |  | 4260|     23|  }                                                                            \
  |  | 4261|     23|  MZ_MACRO_END
  |  |  ------------------
  |  |  |  |  726|     23|#define MZ_MACRO_END while (0)
  |  |  |  |  ------------------
  |  |  |  |  |  Branch (726:29): [Folded, False: 0]
  |  |  |  |  ------------------
  |  |  ------------------
  ------------------
 4725|     23|        }
 4726|       |
 4727|  4.09k|        pSrc = pOut_buf_start +
 4728|  4.09k|               ((dist_from_out_buf_start - dist) & out_buf_size_mask);
 4729|       |
 4730|  4.09k|        if ((MZ_MAX(pOut_buf_cur, pSrc) + counter) > pOut_buf_end) {
  ------------------
  |  |  758|  4.09k|#define MZ_MAX(a, b) (((a) > (b)) ? (a) : (b))
  |  |  ------------------
  |  |  |  Branch (758:23): [True: 4.09k, False: 0]
  |  |  ------------------
  ------------------
  |  Branch (4730:13): [True: 34, False: 4.06k]
  ------------------
 4731|    470|          while (counter--) {
  ------------------
  |  Branch (4731:18): [True: 470, False: 0]
  ------------------
 4732|    470|            while (pOut_buf_cur >= pOut_buf_end) {
  ------------------
  |  Branch (4732:20): [True: 34, False: 436]
  ------------------
 4733|     34|              TINFL_CR_RETURN(53, TINFL_STATUS_HAS_MORE_OUTPUT);
  ------------------
  |  | 4248|     34|  do {                                                                         \
  |  | 4249|     34|    status = result;                                                           \
  |  | 4250|     34|    r->m_state = state_index;                                                  \
  |  | 4251|     34|    goto common_exit;                                                          \
  |  | 4252|     34|  case state_index:;                                                           \
  |  |  ------------------
  |  |  |  Branch (4252:3): [True: 0, False: 468]
  |  |  ------------------
  |  | 4253|      0|  }                                                                            \
  |  | 4254|     34|  MZ_MACRO_END
  |  |  ------------------
  |  |  |  |  726|     34|#define MZ_MACRO_END while (0)
  |  |  |  |  ------------------
  |  |  |  |  |  Branch (726:29): [Folded, False: 0]
  |  |  |  |  ------------------
  |  |  ------------------
  ------------------
 4734|     34|            }
 4735|    436|            *pOut_buf_cur++ =
 4736|    436|                pOut_buf_start[(dist_from_out_buf_start++ - dist) &
 4737|    436|                               out_buf_size_mask];
 4738|    436|          }
 4739|      0|          continue;
 4740|     34|        }
 4741|       |#if MINIZ_USE_UNALIGNED_LOADS_AND_STORES
 4742|       |        else if ((counter >= 9) && (counter <= dist)) {
 4743|       |          const mz_uint8 *pSrc_end = pSrc + (counter & ~7);
 4744|       |          do {
 4745|       |#ifdef MINIZ_UNALIGNED_USE_MEMCPY
 4746|       |            memcpy(pOut_buf_cur, pSrc, sizeof(mz_uint32) * 2);
 4747|       |#else
 4748|       |            ((mz_uint32 *)pOut_buf_cur)[0] = ((const mz_uint32 *)pSrc)[0];
 4749|       |            ((mz_uint32 *)pOut_buf_cur)[1] = ((const mz_uint32 *)pSrc)[1];
 4750|       |#endif
 4751|       |            pOut_buf_cur += 8;
 4752|       |          } while ((pSrc += 8) < pSrc_end);
 4753|       |          if ((counter &= 7) < 3) {
 4754|       |            if (counter) {
 4755|       |              pOut_buf_cur[0] = pSrc[0];
 4756|       |              if (counter > 1)
 4757|       |                pOut_buf_cur[1] = pSrc[1];
 4758|       |              pOut_buf_cur += counter;
 4759|       |            }
 4760|       |            continue;
 4761|       |          }
 4762|       |        }
 4763|       |#endif
 4764|  37.0k|        while (counter > 2) {
  ------------------
  |  Branch (4764:16): [True: 32.9k, False: 4.06k]
  ------------------
 4765|  32.9k|          pOut_buf_cur[0] = pSrc[0];
 4766|  32.9k|          pOut_buf_cur[1] = pSrc[1];
 4767|  32.9k|          pOut_buf_cur[2] = pSrc[2];
 4768|  32.9k|          pOut_buf_cur += 3;
 4769|  32.9k|          pSrc += 3;
 4770|  32.9k|          counter -= 3;
 4771|  32.9k|        }
 4772|  4.06k|        if (counter > 0) {
  ------------------
  |  Branch (4772:13): [True: 2.53k, False: 1.52k]
  ------------------
 4773|  2.53k|          pOut_buf_cur[0] = pSrc[0];
 4774|  2.53k|          if (counter > 1)
  ------------------
  |  Branch (4774:15): [True: 647, False: 1.89k]
  ------------------
 4775|    647|            pOut_buf_cur[1] = pSrc[1];
 4776|  2.53k|          pOut_buf_cur += counter;
 4777|  2.53k|        }
 4778|  4.06k|      }
 4779|  1.38k|    }
 4780|  1.70k|  } while (!(r->m_final & 1));
  ------------------
  |  Branch (4780:12): [True: 1.26k, False: 73]
  ------------------
 4781|       |
 4782|       |  /* Ensure byte alignment and put back any bytes from the bitbuf if we've
 4783|       |   * looked ahead too far on gzip, or other Deflate streams followed by
 4784|       |   * arbitrary data. */
 4785|       |  /* I'm being super conservative here. A number of simplifications can be made
 4786|       |   * to the byte alignment part, and the Adler32 check shouldn't ever need to
 4787|       |   * worry about reading from the bitbuf now. */
 4788|     73|  TINFL_SKIP_BITS(32, num_bits & 7);
  ------------------
  |  | 4284|     73|  do {                                                                         \
  |  | 4285|     73|    if (num_bits < (mz_uint)(n)) {                                             \
  |  |  ------------------
  |  |  |  Branch (4285:9): [True: 0, False: 73]
  |  |  ------------------
  |  | 4286|      0|      TINFL_NEED_BITS(state_index, n);                                         \
  |  |  ------------------
  |  |  |  | 4277|      0|  do {                                                                         \
  |  |  |  | 4278|      0|    mz_uint c;                                                                 \
  |  |  |  | 4279|      0|    TINFL_GET_BYTE(state_index, c);                                            \
  |  |  |  |  ------------------
  |  |  |  |  |  | 4265|      0|  do {                                                                         \
  |  |  |  |  |  | 4266|      0|    while (pIn_buf_cur >= pIn_buf_end) {                                       \
  |  |  |  |  |  |  ------------------
  |  |  |  |  |  |  |  Branch (4266:12): [True: 0, False: 0]
  |  |  |  |  |  |  ------------------
  |  |  |  |  |  | 4267|      0|      TINFL_CR_RETURN(state_index,                                             \
  |  |  |  |  |  |  ------------------
  |  |  |  |  |  |  |  | 4248|      0|  do {                                                                         \
  |  |  |  |  |  |  |  | 4249|      0|    status = result;                                                           \
  |  |  |  |  |  |  |  |  ------------------
  |  |  |  |  |  |  |  |  |  Branch (4249:14): [True: 0, False: 0]
  |  |  |  |  |  |  |  |  ------------------
  |  |  |  |  |  |  |  | 4250|      0|    r->m_state = state_index;                                                  \
  |  |  |  |  |  |  |  | 4251|      0|    goto common_exit;                                                          \
  |  |  |  |  |  |  |  | 4252|      0|  case state_index:;                                                           \
  |  |  |  |  |  |  |  |  ------------------
  |  |  |  |  |  |  |  |  |  Branch (4252:3): [True: 0, False: 468]
  |  |  |  |  |  |  |  |  ------------------
  |  |  |  |  |  |  |  | 4253|      0|  }                                                                            \
  |  |  |  |  |  |  |  | 4254|      0|  MZ_MACRO_END
  |  |  |  |  |  |  |  |  ------------------
  |  |  |  |  |  |  |  |  |  |  726|      0|#define MZ_MACRO_END while (0)
  |  |  |  |  |  |  |  |  |  |  ------------------
  |  |  |  |  |  |  |  |  |  |  |  Branch (726:29): [Folded, False: 0]
  |  |  |  |  |  |  |  |  |  |  ------------------
  |  |  |  |  |  |  |  |  ------------------
  |  |  |  |  |  |  ------------------
  |  |  |  |  |  | 4268|      0|                      (decomp_flags & TINFL_FLAG_HAS_MORE_INPUT)               \
  |  |  |  |  |  | 4269|      0|                          ? TINFL_STATUS_NEEDS_MORE_INPUT                      \
  |  |  |  |  |  | 4270|      0|                          : TINFL_STATUS_FAILED_CANNOT_MAKE_PROGRESS);         \
  |  |  |  |  |  | 4271|      0|    }                                                                          \
  |  |  |  |  |  | 4272|      0|    c = *pIn_buf_cur++;                                                        \
  |  |  |  |  |  | 4273|      0|  }                                                                            \
  |  |  |  |  |  | 4274|      0|  MZ_MACRO_END
  |  |  |  |  |  |  ------------------
  |  |  |  |  |  |  |  |  726|      0|#define MZ_MACRO_END while (0)
  |  |  |  |  |  |  |  |  ------------------
  |  |  |  |  |  |  |  |  |  Branch (726:29): [Folded, False: 0]
  |  |  |  |  |  |  |  |  ------------------
  |  |  |  |  |  |  ------------------
  |  |  |  |  ------------------
  |  |  |  | 4280|      0|    bit_buf |= (((tinfl_bit_buf_t)c) << num_bits);                             \
  |  |  |  | 4281|      0|    num_bits += 8;                                                             \
  |  |  |  | 4282|      0|  } while (num_bits < (mz_uint)(n))
  |  |  |  |  ------------------
  |  |  |  |  |  Branch (4282:12): [True: 0, False: 0]
  |  |  |  |  ------------------
  |  |  ------------------
  |  | 4287|      0|    }                                                                          \
  |  | 4288|     73|    bit_buf >>= (n);                                                           \
  |  | 4289|     73|    num_bits -= (n);                                                           \
  |  | 4290|     73|  }                                                                            \
  |  | 4291|    468|  MZ_MACRO_END
  |  |  ------------------
  |  |  |  |  726|    468|#define MZ_MACRO_END while (0)
  |  |  |  |  ------------------
  |  |  |  |  |  Branch (726:29): [Folded, False: 73]
  |  |  |  |  ------------------
  |  |  ------------------
  ------------------
 4789|    223|  while ((pIn_buf_cur > pIn_buf_next) && (num_bits >= 8)) {
  ------------------
  |  Branch (4789:10): [True: 223, False: 0]
  |  Branch (4789:42): [True: 150, False: 73]
  ------------------
 4790|    150|    --pIn_buf_cur;
 4791|    150|    num_bits -= 8;
 4792|    150|  }
 4793|     73|  bit_buf &= ~(~(tinfl_bit_buf_t)0 << num_bits);
 4794|     73|  MZ_ASSERT(!num_bits); /* if this assert fires then we've read beyond the end
  ------------------
  |  |  746|     73|#define MZ_ASSERT(x) assert(x)
  ------------------
 4795|       |                           of non-deflate/zlib streams with following data (such
 4796|       |                           as gzip streams). */
 4797|       |
 4798|     73|  if (decomp_flags & TINFL_FLAG_PARSE_ZLIB_HEADER) {
  ------------------
  |  Branch (4798:7): [True: 0, False: 73]
  ------------------
 4799|      0|    for (counter = 0; counter < 4; ++counter) {
  ------------------
  |  Branch (4799:23): [True: 0, False: 0]
  ------------------
 4800|      0|      mz_uint s;
 4801|      0|      if (num_bits)
  ------------------
  |  Branch (4801:11): [True: 0, False: 0]
  ------------------
 4802|      0|        TINFL_GET_BITS(41, s, 8);
  ------------------
  |  | 4293|      0|  do {                                                                         \
  |  | 4294|      0|    if (num_bits < (mz_uint)(n)) {                                             \
  |  |  ------------------
  |  |  |  Branch (4294:9): [True: 0, False: 0]
  |  |  ------------------
  |  | 4295|      0|      TINFL_NEED_BITS(state_index, n);                                         \
  |  |  ------------------
  |  |  |  | 4277|      0|  do {                                                                         \
  |  |  |  | 4278|      0|    mz_uint c;                                                                 \
  |  |  |  | 4279|      0|    TINFL_GET_BYTE(state_index, c);                                            \
  |  |  |  |  ------------------
  |  |  |  |  |  | 4265|      0|  do {                                                                         \
  |  |  |  |  |  | 4266|      0|    while (pIn_buf_cur >= pIn_buf_end) {                                       \
  |  |  |  |  |  |  ------------------
  |  |  |  |  |  |  |  Branch (4266:12): [True: 0, False: 0]
  |  |  |  |  |  |  ------------------
  |  |  |  |  |  | 4267|      0|      TINFL_CR_RETURN(state_index,                                             \
  |  |  |  |  |  |  ------------------
  |  |  |  |  |  |  |  | 4248|      0|  do {                                                                         \
  |  |  |  |  |  |  |  | 4249|      0|    status = result;                                                           \
  |  |  |  |  |  |  |  |  ------------------
  |  |  |  |  |  |  |  |  |  Branch (4249:14): [True: 0, False: 0]
  |  |  |  |  |  |  |  |  ------------------
  |  |  |  |  |  |  |  | 4250|      0|    r->m_state = state_index;                                                  \
  |  |  |  |  |  |  |  | 4251|      0|    goto common_exit;                                                          \
  |  |  |  |  |  |  |  | 4252|      0|  case state_index:;                                                           \
  |  |  |  |  |  |  |  |  ------------------
  |  |  |  |  |  |  |  |  |  Branch (4252:3): [True: 0, False: 468]
  |  |  |  |  |  |  |  |  ------------------
  |  |  |  |  |  |  |  | 4253|      0|  }                                                                            \
  |  |  |  |  |  |  |  | 4254|      0|  MZ_MACRO_END
  |  |  |  |  |  |  |  |  ------------------
  |  |  |  |  |  |  |  |  |  |  726|      0|#define MZ_MACRO_END while (0)
  |  |  |  |  |  |  |  |  |  |  ------------------
  |  |  |  |  |  |  |  |  |  |  |  Branch (726:29): [Folded, False: 0]
  |  |  |  |  |  |  |  |  |  |  ------------------
  |  |  |  |  |  |  |  |  ------------------
  |  |  |  |  |  |  ------------------
  |  |  |  |  |  | 4268|      0|                      (decomp_flags & TINFL_FLAG_HAS_MORE_INPUT)               \
  |  |  |  |  |  | 4269|      0|                          ? TINFL_STATUS_NEEDS_MORE_INPUT                      \
  |  |  |  |  |  | 4270|      0|                          : TINFL_STATUS_FAILED_CANNOT_MAKE_PROGRESS);         \
  |  |  |  |  |  | 4271|      0|    }                                                                          \
  |  |  |  |  |  | 4272|      0|    c = *pIn_buf_cur++;                                                        \
  |  |  |  |  |  | 4273|      0|  }                                                                            \
  |  |  |  |  |  | 4274|      0|  MZ_MACRO_END
  |  |  |  |  |  |  ------------------
  |  |  |  |  |  |  |  |  726|      0|#define MZ_MACRO_END while (0)
  |  |  |  |  |  |  |  |  ------------------
  |  |  |  |  |  |  |  |  |  Branch (726:29): [Folded, False: 0]
  |  |  |  |  |  |  |  |  ------------------
  |  |  |  |  |  |  ------------------
  |  |  |  |  ------------------
  |  |  |  | 4280|      0|    bit_buf |= (((tinfl_bit_buf_t)c) << num_bits);                             \
  |  |  |  | 4281|      0|    num_bits += 8;                                                             \
  |  |  |  | 4282|      0|  } while (num_bits < (mz_uint)(n))
  |  |  |  |  ------------------
  |  |  |  |  |  Branch (4282:12): [True: 0, False: 0]
  |  |  |  |  ------------------
  |  |  ------------------
  |  | 4296|      0|    }                                                                          \
  |  | 4297|      0|    b = bit_buf & ((1 << (n)) - 1);                                            \
  |  | 4298|      0|    bit_buf >>= (n);                                                           \
  |  | 4299|      0|    num_bits -= (n);                                                           \
  |  | 4300|      0|  }                                                                            \
  |  | 4301|      0|  MZ_MACRO_END
  |  |  ------------------
  |  |  |  |  726|      0|#define MZ_MACRO_END while (0)
  |  |  |  |  ------------------
  |  |  |  |  |  Branch (726:29): [Folded, False: 0]
  |  |  |  |  ------------------
  |  |  ------------------
  ------------------
 4803|      0|      else
 4804|      0|        TINFL_GET_BYTE(42, s);
  ------------------
  |  | 4265|      0|  do {                                                                         \
  |  | 4266|      0|    while (pIn_buf_cur >= pIn_buf_end) {                                       \
  |  |  ------------------
  |  |  |  Branch (4266:12): [True: 0, False: 0]
  |  |  ------------------
  |  | 4267|      0|      TINFL_CR_RETURN(state_index,                                             \
  |  |  ------------------
  |  |  |  | 4248|      0|  do {                                                                         \
  |  |  |  | 4249|      0|    status = result;                                                           \
  |  |  |  |  ------------------
  |  |  |  |  |  Branch (4249:14): [True: 0, False: 0]
  |  |  |  |  ------------------
  |  |  |  | 4250|      0|    r->m_state = state_index;                                                  \
  |  |  |  | 4251|      0|    goto common_exit;                                                          \
  |  |  |  | 4252|      0|  case state_index:;                                                           \
  |  |  |  |  ------------------
  |  |  |  |  |  Branch (4252:3): [True: 0, False: 468]
  |  |  |  |  ------------------
  |  |  |  | 4253|      0|  }                                                                            \
  |  |  |  | 4254|      0|  MZ_MACRO_END
  |  |  |  |  ------------------
  |  |  |  |  |  |  726|      0|#define MZ_MACRO_END while (0)
  |  |  |  |  |  |  ------------------
  |  |  |  |  |  |  |  Branch (726:29): [Folded, False: 0]
  |  |  |  |  |  |  ------------------
  |  |  |  |  ------------------
  |  |  ------------------
  |  | 4268|      0|                      (decomp_flags & TINFL_FLAG_HAS_MORE_INPUT)               \
  |  | 4269|      0|                          ? TINFL_STATUS_NEEDS_MORE_INPUT                      \
  |  | 4270|      0|                          : TINFL_STATUS_FAILED_CANNOT_MAKE_PROGRESS);         \
  |  | 4271|      0|    }                                                                          \
  |  | 4272|      0|    c = *pIn_buf_cur++;                                                        \
  |  | 4273|      0|  }                                                                            \
  |  | 4274|      0|  MZ_MACRO_END
  |  |  ------------------
  |  |  |  |  726|      0|#define MZ_MACRO_END while (0)
  |  |  |  |  ------------------
  |  |  |  |  |  Branch (726:29): [Folded, False: 0]
  |  |  |  |  ------------------
  |  |  ------------------
  ------------------
 4805|      0|      r->m_z_adler32 = (r->m_z_adler32 << 8) | s;
 4806|      0|    }
 4807|      0|  }
 4808|    468|  TINFL_CR_RETURN_FOREVER(34, TINFL_STATUS_DONE);
  ------------------
  |  | 4256|     73|  do {                                                                         \
  |  | 4257|     73|    for (;;) {                                                                 \
  |  | 4258|     73|      TINFL_CR_RETURN(state_index, result);                                    \
  |  |  ------------------
  |  |  |  | 4248|     73|  do {                                                                         \
  |  |  |  | 4249|     73|    status = result;                                                           \
  |  |  |  | 4250|     73|    r->m_state = state_index;                                                  \
  |  |  |  | 4251|     73|    goto common_exit;                                                          \
  |  |  |  | 4252|     73|  case state_index:;                                                           \
  |  |  |  |  ------------------
  |  |  |  |  |  Branch (4252:3): [True: 0, False: 468]
  |  |  |  |  ------------------
  |  |  |  | 4253|      0|  }                                                                            \
  |  |  |  | 4254|     73|  MZ_MACRO_END
  |  |  |  |  ------------------
  |  |  |  |  |  |  726|     73|#define MZ_MACRO_END while (0)
  |  |  |  |  |  |  ------------------
  |  |  |  |  |  |  |  Branch (726:29): [Folded, False: 0]
  |  |  |  |  |  |  ------------------
  |  |  |  |  ------------------
  |  |  ------------------
  |  | 4259|     73|    }                                                                          \
  |  | 4260|     73|  }                                                                            \
  |  | 4261|     73|  MZ_MACRO_END
  |  |  ------------------
  |  |  |  |  726|     73|#define MZ_MACRO_END while (0)
  |  |  |  |  ------------------
  |  |  |  |  |  Branch (726:29): [Folded, False: 0]
  |  |  |  |  ------------------
  |  |  ------------------
  ------------------
 4809|       |
 4810|    468|  TINFL_CR_FINISH
  ------------------
  |  | 4262|    468|#define TINFL_CR_FINISH }
  ------------------
 4811|       |
 4812|    468|common_exit:
 4813|       |  /* As long as we aren't telling the caller that we NEED more input to make
 4814|       |   * forward progress: */
 4815|       |  /* Put back any bytes from the bitbuf in case we've looked ahead too far on
 4816|       |   * gzip, or other Deflate streams followed by arbitrary data. */
 4817|       |  /* We need to be very careful here to NOT push back any bytes we definitely
 4818|       |   * know we need to make forward progress, though, or we'll lock the caller up
 4819|       |   * into an inf loop. */
 4820|    468|  if ((status != TINFL_STATUS_NEEDS_MORE_INPUT) &&
  ------------------
  |  Branch (4820:7): [True: 468, False: 0]
  ------------------
 4821|    468|      (status != TINFL_STATUS_FAILED_CANNOT_MAKE_PROGRESS)) {
  ------------------
  |  Branch (4821:7): [True: 306, False: 162]
  ------------------
 4822|    822|    while ((pIn_buf_cur > pIn_buf_next) && (num_bits >= 8)) {
  ------------------
  |  Branch (4822:12): [True: 822, False: 0]
  |  Branch (4822:44): [True: 516, False: 306]
  ------------------
 4823|    516|      --pIn_buf_cur;
 4824|    516|      num_bits -= 8;
 4825|    516|    }
 4826|    306|  }
 4827|    468|  r->m_num_bits = num_bits;
 4828|    468|  r->m_bit_buf = bit_buf & ~(~(tinfl_bit_buf_t)0 << num_bits);
 4829|    468|  r->m_dist = dist;
 4830|    468|  r->m_counter = counter;
 4831|    468|  r->m_num_extra = num_extra;
 4832|    468|  r->m_dist_from_out_buf_start = dist_from_out_buf_start;
 4833|    468|  *pIn_buf_size = pIn_buf_cur - pIn_buf_next;
 4834|    468|  *pOut_buf_size = pOut_buf_cur - pOut_buf_next;
 4835|    468|  if ((decomp_flags &
  ------------------
  |  Branch (4835:7): [True: 0, False: 468]
  ------------------
 4836|    468|       (TINFL_FLAG_PARSE_ZLIB_HEADER | TINFL_FLAG_COMPUTE_ADLER32)) &&
 4837|      0|      (status >= 0)) {
  ------------------
  |  Branch (4837:7): [True: 0, False: 0]
  ------------------
 4838|      0|    const mz_uint8 *ptr = pOut_buf_next;
 4839|      0|    size_t buf_len = *pOut_buf_size;
 4840|      0|    mz_uint32 i, s1 = r->m_check_adler32 & 0xffff,
 4841|      0|                 s2 = r->m_check_adler32 >> 16;
 4842|      0|    size_t block_len = buf_len % 5552;
 4843|      0|    while (buf_len) {
  ------------------
  |  Branch (4843:12): [True: 0, False: 0]
  ------------------
 4844|      0|      for (i = 0; i + 7 < block_len; i += 8, ptr += 8) {
  ------------------
  |  Branch (4844:19): [True: 0, False: 0]
  ------------------
 4845|      0|        s1 += ptr[0], s2 += s1;
 4846|      0|        s1 += ptr[1], s2 += s1;
 4847|      0|        s1 += ptr[2], s2 += s1;
 4848|      0|        s1 += ptr[3], s2 += s1;
 4849|      0|        s1 += ptr[4], s2 += s1;
 4850|      0|        s1 += ptr[5], s2 += s1;
 4851|      0|        s1 += ptr[6], s2 += s1;
 4852|      0|        s1 += ptr[7], s2 += s1;
 4853|      0|      }
 4854|      0|      for (; i < block_len; ++i)
  ------------------
  |  Branch (4854:14): [True: 0, False: 0]
  ------------------
 4855|      0|        s1 += *ptr++, s2 += s1;
 4856|      0|      s1 %= 65521U, s2 %= 65521U;
 4857|      0|      buf_len -= block_len;
 4858|      0|      block_len = 5552;
 4859|      0|    }
 4860|      0|    r->m_check_adler32 = (s2 << 16) + s1;
 4861|      0|    if ((status == TINFL_STATUS_DONE) &&
  ------------------
  |  Branch (4861:9): [True: 0, False: 0]
  ------------------
 4862|      0|        (decomp_flags & TINFL_FLAG_PARSE_ZLIB_HEADER) &&
  ------------------
  |  Branch (4862:9): [True: 0, False: 0]
  ------------------
 4863|      0|        (r->m_check_adler32 != r->m_z_adler32))
  ------------------
  |  Branch (4863:9): [True: 0, False: 0]
  ------------------
 4864|      0|      status = TINFL_STATUS_ADLER32_MISMATCH;
 4865|      0|  }
 4866|    468|  return status;
 4867|    468|}
mz_zip_reader_end:
 6094|  2.55k|mz_bool mz_zip_reader_end(mz_zip_archive *pZip) {
 6095|  2.55k|  return mz_zip_reader_end_internal(pZip, MZ_TRUE);
  ------------------
  |  |  719|  2.55k|#define MZ_TRUE (1)
  ------------------
 6096|  2.55k|}
mz_zip_reader_init_mem:
 6127|  3.83k|                               size_t size, mz_uint flags) {
 6128|  3.83k|  if (!pMem)
  ------------------
  |  Branch (6128:7): [True: 0, False: 3.83k]
  ------------------
 6129|      0|    return mz_zip_set_error(pZip, MZ_ZIP_INVALID_PARAMETER);
 6130|       |
 6131|  3.83k|  if (size < MZ_ZIP_END_OF_CENTRAL_DIR_HEADER_SIZE)
  ------------------
  |  Branch (6131:7): [True: 10, False: 3.82k]
  ------------------
 6132|     10|    return mz_zip_set_error(pZip, MZ_ZIP_NOT_AN_ARCHIVE);
 6133|       |
 6134|  3.82k|  if (!mz_zip_reader_init_internal(pZip, flags))
  ------------------
  |  Branch (6134:7): [True: 0, False: 3.82k]
  ------------------
 6135|      0|    return MZ_FALSE;
  ------------------
  |  |  718|      0|#define MZ_FALSE (0)
  ------------------
 6136|       |
 6137|  3.82k|  pZip->m_zip_type = MZ_ZIP_TYPE_MEMORY;
 6138|  3.82k|  pZip->m_archive_size = size;
 6139|  3.82k|  pZip->m_pRead = mz_zip_mem_read_func;
 6140|  3.82k|  pZip->m_pIO_opaque = pZip;
 6141|  3.82k|  pZip->m_pNeeds_keepalive = NULL;
 6142|       |
 6143|       |#ifdef __cplusplus
 6144|       |  pZip->m_pState->m_pMem = const_cast<void *>(pMem);
 6145|       |#else
 6146|  3.82k|  pZip->m_pState->m_pMem = (void *)pMem;
 6147|  3.82k|#endif
 6148|       |
 6149|  3.82k|  pZip->m_pState->m_mem_size = size;
 6150|       |
 6151|  3.82k|  if (!mz_zip_reader_read_central_dir(pZip, flags)) {
  ------------------
  |  Branch (6151:7): [True: 1.26k, False: 2.55k]
  ------------------
 6152|  1.26k|    mz_zip_reader_end_internal(pZip, MZ_FALSE);
  ------------------
  |  |  718|  1.26k|#define MZ_FALSE (0)
  ------------------
 6153|  1.26k|    return MZ_FALSE;
  ------------------
  |  |  718|  1.26k|#define MZ_FALSE (0)
  ------------------
 6154|  1.26k|  }
 6155|       |
 6156|  2.55k|  return MZ_TRUE;
  ------------------
  |  |  719|  2.55k|#define MZ_TRUE (1)
  ------------------
 6157|  3.82k|}
mz_zip_reader_is_file_encrypted:
 6285|  7.99k|                                        mz_uint file_index) {
 6286|  7.99k|  mz_uint m_bit_flag;
 6287|  7.99k|  const mz_uint8 *p = mz_zip_get_cdh(pZip, file_index);
 6288|  7.99k|  if (!p) {
  ------------------
  |  Branch (6288:7): [True: 0, False: 7.99k]
  ------------------
 6289|      0|    mz_zip_set_error(pZip, MZ_ZIP_INVALID_PARAMETER);
 6290|      0|    return MZ_FALSE;
  ------------------
  |  |  718|      0|#define MZ_FALSE (0)
  ------------------
 6291|      0|  }
 6292|       |
 6293|  7.99k|  m_bit_flag = MZ_READ_LE16(p + MZ_ZIP_CDH_BIT_FLAG_OFS);
  ------------------
  |  |  769|  7.99k|  ((mz_uint32)(((const mz_uint8 *)(p))[0]) |                                   \
  |  |  770|  7.99k|   ((mz_uint32)(((const mz_uint8 *)(p))[1]) << 8U))
  ------------------
 6294|  7.99k|  return (m_bit_flag &
 6295|  7.99k|          (MZ_ZIP_GENERAL_PURPOSE_BIT_FLAG_IS_ENCRYPTED |
 6296|  7.99k|           MZ_ZIP_GENERAL_PURPOSE_BIT_FLAG_USES_STRONG_ENCRYPTION)) != 0;
 6297|  7.99k|}
mz_zip_reader_is_file_supported:
 6300|  7.99k|                                        mz_uint file_index) {
 6301|  7.99k|  mz_uint bit_flag;
 6302|  7.99k|  mz_uint method;
 6303|       |
 6304|  7.99k|  const mz_uint8 *p = mz_zip_get_cdh(pZip, file_index);
 6305|  7.99k|  if (!p) {
  ------------------
  |  Branch (6305:7): [True: 0, False: 7.99k]
  ------------------
 6306|      0|    mz_zip_set_error(pZip, MZ_ZIP_INVALID_PARAMETER);
 6307|      0|    return MZ_FALSE;
  ------------------
  |  |  718|      0|#define MZ_FALSE (0)
  ------------------
 6308|      0|  }
 6309|       |
 6310|  7.99k|  method = MZ_READ_LE16(p + MZ_ZIP_CDH_METHOD_OFS);
  ------------------
  |  |  769|  7.99k|  ((mz_uint32)(((const mz_uint8 *)(p))[0]) |                                   \
  |  |  770|  7.99k|   ((mz_uint32)(((const mz_uint8 *)(p))[1]) << 8U))
  ------------------
 6311|  7.99k|  bit_flag = MZ_READ_LE16(p + MZ_ZIP_CDH_BIT_FLAG_OFS);
  ------------------
  |  |  769|  7.99k|  ((mz_uint32)(((const mz_uint8 *)(p))[0]) |                                   \
  |  |  770|  7.99k|   ((mz_uint32)(((const mz_uint8 *)(p))[1]) << 8U))
  ------------------
 6312|       |
 6313|  7.99k|  if ((method != 0) && (method != MZ_DEFLATED)) {
  ------------------
  |  |  316|  5.03k|#define MZ_DEFLATED 8
  ------------------
  |  Branch (6313:7): [True: 5.03k, False: 2.96k]
  |  Branch (6313:24): [True: 2.10k, False: 2.93k]
  ------------------
 6314|  2.10k|    mz_zip_set_error(pZip, MZ_ZIP_UNSUPPORTED_METHOD);
 6315|  2.10k|    return MZ_FALSE;
  ------------------
  |  |  718|  2.10k|#define MZ_FALSE (0)
  ------------------
 6316|  2.10k|  }
 6317|       |
 6318|  5.89k|  if (bit_flag & (MZ_ZIP_GENERAL_PURPOSE_BIT_FLAG_IS_ENCRYPTED |
  ------------------
  |  Branch (6318:7): [True: 864, False: 5.02k]
  ------------------
 6319|  5.89k|                  MZ_ZIP_GENERAL_PURPOSE_BIT_FLAG_USES_STRONG_ENCRYPTION)) {
 6320|    864|    mz_zip_set_error(pZip, MZ_ZIP_UNSUPPORTED_ENCRYPTION);
 6321|    864|    return MZ_FALSE;
  ------------------
  |  |  718|    864|#define MZ_FALSE (0)
  ------------------
 6322|    864|  }
 6323|       |
 6324|  5.02k|  if (bit_flag & MZ_ZIP_GENERAL_PURPOSE_BIT_FLAG_COMPRESSED_PATCH_FLAG) {
  ------------------
  |  Branch (6324:7): [True: 219, False: 4.80k]
  ------------------
 6325|    219|    mz_zip_set_error(pZip, MZ_ZIP_UNSUPPORTED_FEATURE);
 6326|    219|    return MZ_FALSE;
  ------------------
  |  |  718|    219|#define MZ_FALSE (0)
  ------------------
 6327|    219|  }
 6328|       |
 6329|  4.80k|  return MZ_TRUE;
  ------------------
  |  |  719|  4.80k|#define MZ_TRUE (1)
  ------------------
 6330|  5.02k|}
mz_zip_reader_is_file_a_directory:
 6333|  7.99k|                                          mz_uint file_index) {
 6334|  7.99k|  mz_uint filename_len, attribute_mapping_id, external_attr;
 6335|  7.99k|  const mz_uint8 *p = mz_zip_get_cdh(pZip, file_index);
 6336|  7.99k|  if (!p) {
  ------------------
  |  Branch (6336:7): [True: 0, False: 7.99k]
  ------------------
 6337|      0|    mz_zip_set_error(pZip, MZ_ZIP_INVALID_PARAMETER);
 6338|      0|    return MZ_FALSE;
  ------------------
  |  |  718|      0|#define MZ_FALSE (0)
  ------------------
 6339|      0|  }
 6340|       |
 6341|  7.99k|  filename_len = MZ_READ_LE16(p + MZ_ZIP_CDH_FILENAME_LEN_OFS);
  ------------------
  |  |  769|  7.99k|  ((mz_uint32)(((const mz_uint8 *)(p))[0]) |                                   \
  |  |  770|  7.99k|   ((mz_uint32)(((const mz_uint8 *)(p))[1]) << 8U))
  ------------------
 6342|  7.99k|  if (filename_len) {
  ------------------
  |  Branch (6342:7): [True: 7.76k, False: 227]
  ------------------
 6343|  7.76k|    if (*(p + MZ_ZIP_CENTRAL_DIR_HEADER_SIZE + filename_len - 1) == '/')
  ------------------
  |  Branch (6343:9): [True: 17, False: 7.75k]
  ------------------
 6344|     17|      return MZ_TRUE;
  ------------------
  |  |  719|     17|#define MZ_TRUE (1)
  ------------------
 6345|  7.76k|  }
 6346|       |
 6347|       |  /* Bugfix: This code was also checking if the internal attribute was non-zero,
 6348|       |   * which wasn't correct. */
 6349|       |  /* Most/all zip writers (hopefully) set DOS file/directory attributes in the
 6350|       |   * low 16-bits, so check for the DOS directory flag and ignore the source OS
 6351|       |   * ID in the created by field. */
 6352|       |  /* FIXME: Remove this check? Is it necessary - we already check the filename.
 6353|       |   */
 6354|  7.97k|  attribute_mapping_id = MZ_READ_LE16(p + MZ_ZIP_CDH_VERSION_MADE_BY_OFS) >> 8;
  ------------------
  |  |  769|  7.97k|  ((mz_uint32)(((const mz_uint8 *)(p))[0]) |                                   \
  |  |  770|  7.97k|   ((mz_uint32)(((const mz_uint8 *)(p))[1]) << 8U))
  ------------------
 6355|  7.97k|  (void)attribute_mapping_id;
 6356|       |
 6357|  7.97k|  external_attr = MZ_READ_LE32(p + MZ_ZIP_CDH_EXTERNAL_ATTR_OFS);
  ------------------
  |  |  772|  7.97k|  ((mz_uint32)(((const mz_uint8 *)(p))[0]) |                                   \
  |  |  773|  7.97k|   ((mz_uint32)(((const mz_uint8 *)(p))[1]) << 8U) |                           \
  |  |  774|  7.97k|   ((mz_uint32)(((const mz_uint8 *)(p))[2]) << 16U) |                          \
  |  |  775|  7.97k|   ((mz_uint32)(((const mz_uint8 *)(p))[3]) << 24U))
  ------------------
 6358|  7.97k|  if ((external_attr & MZ_ZIP_DOS_DIR_ATTRIBUTE_BITFLAG) != 0) {
  ------------------
  |  Branch (6358:7): [True: 1.87k, False: 6.10k]
  ------------------
 6359|  1.87k|    return MZ_TRUE;
  ------------------
  |  |  719|  1.87k|#define MZ_TRUE (1)
  ------------------
 6360|  1.87k|  }
 6361|       |
 6362|  6.10k|  return MZ_FALSE;
  ------------------
  |  |  718|  6.10k|#define MZ_FALSE (0)
  ------------------
 6363|  7.97k|}
mz_zip_reader_locate_file:
 6570|  3.06k|                              const char *pComment, mz_uint flags) {
 6571|  3.06k|  mz_uint32 index;
 6572|  3.06k|  if (!mz_zip_reader_locate_file_v2(pZip, pName, pComment, flags, &index))
  ------------------
  |  Branch (6572:7): [True: 548, False: 2.51k]
  ------------------
 6573|    548|    return -1;
 6574|  2.51k|  else
 6575|  2.51k|    return (int)index;
 6576|  3.06k|}
mz_zip_reader_locate_file_v2:
 6580|  3.06k|                                     mz_uint32 *pIndex) {
 6581|  3.06k|  mz_uint file_index;
 6582|  3.06k|  size_t name_len, comment_len;
 6583|       |
 6584|  3.06k|  if (pIndex)
  ------------------
  |  Branch (6584:7): [True: 3.06k, False: 0]
  ------------------
 6585|  3.06k|    *pIndex = 0;
 6586|       |
 6587|  3.06k|  if ((!pZip) || (!pZip->m_pState) || (!pName))
  ------------------
  |  Branch (6587:7): [True: 0, False: 3.06k]
  |  Branch (6587:18): [True: 0, False: 3.06k]
  |  Branch (6587:39): [True: 0, False: 3.06k]
  ------------------
 6588|      0|    return mz_zip_set_error(pZip, MZ_ZIP_INVALID_PARAMETER);
 6589|       |
 6590|       |  /* See if we can use a binary search */
 6591|  3.06k|  if (((pZip->m_pState->m_init_flags &
  ------------------
  |  Branch (6591:7): [True: 3.06k, False: 0]
  ------------------
 6592|  3.06k|        MZ_ZIP_FLAG_DO_NOT_SORT_CENTRAL_DIRECTORY) == 0) &&
 6593|  3.06k|      (pZip->m_zip_mode == MZ_ZIP_MODE_READING) &&
  ------------------
  |  Branch (6593:7): [True: 3.06k, False: 0]
  ------------------
 6594|  3.06k|      ((flags & (MZ_ZIP_FLAG_IGNORE_PATH | MZ_ZIP_FLAG_CASE_SENSITIVE)) == 0) &&
  ------------------
  |  Branch (6594:7): [True: 0, False: 3.06k]
  ------------------
 6595|      0|      (!pComment) && (pZip->m_pState->m_sorted_central_dir_offsets.m_size)) {
  ------------------
  |  Branch (6595:7): [True: 0, False: 0]
  |  Branch (6595:22): [True: 0, False: 0]
  ------------------
 6596|      0|    return mz_zip_locate_file_binary_search(pZip, pName, pIndex);
 6597|      0|  }
 6598|       |
 6599|       |  /* Locate the entry by scanning the entire central directory */
 6600|  3.06k|  name_len = strlen(pName);
 6601|  3.06k|  if (name_len > MZ_UINT16_MAX)
  ------------------
  |  |  793|  3.06k|#define MZ_UINT16_MAX (0xFFFFU)
  ------------------
  |  Branch (6601:7): [True: 0, False: 3.06k]
  ------------------
 6602|      0|    return mz_zip_set_error(pZip, MZ_ZIP_INVALID_PARAMETER);
 6603|       |
 6604|  3.06k|  comment_len = pComment ? strlen(pComment) : 0;
  ------------------
  |  Branch (6604:17): [True: 0, False: 3.06k]
  ------------------
 6605|  3.06k|  if (comment_len > MZ_UINT16_MAX)
  ------------------
  |  |  793|  3.06k|#define MZ_UINT16_MAX (0xFFFFU)
  ------------------
  |  Branch (6605:7): [True: 0, False: 3.06k]
  ------------------
 6606|      0|    return mz_zip_set_error(pZip, MZ_ZIP_INVALID_PARAMETER);
 6607|       |
 6608|  6.28k|  for (file_index = 0; file_index < pZip->m_total_files; file_index++) {
  ------------------
  |  Branch (6608:24): [True: 5.73k, False: 548]
  ------------------
 6609|  5.73k|    const mz_uint8 *pHeader = &MZ_ZIP_ARRAY_ELEMENT(
  ------------------
  |  | 5355|  5.73k|  ((element_type *)((array_ptr)->m_p))[index]
  ------------------
 6610|  5.73k|        &pZip->m_pState->m_central_dir, mz_uint8,
 6611|  5.73k|        MZ_ZIP_ARRAY_ELEMENT(&pZip->m_pState->m_central_dir_offsets, mz_uint32,
 6612|  5.73k|                             file_index));
 6613|  5.73k|    mz_uint filename_len = MZ_READ_LE16(pHeader + MZ_ZIP_CDH_FILENAME_LEN_OFS);
  ------------------
  |  |  769|  5.73k|  ((mz_uint32)(((const mz_uint8 *)(p))[0]) |                                   \
  |  |  770|  5.73k|   ((mz_uint32)(((const mz_uint8 *)(p))[1]) << 8U))
  ------------------
 6614|  5.73k|    const char *pFilename =
 6615|  5.73k|        (const char *)pHeader + MZ_ZIP_CENTRAL_DIR_HEADER_SIZE;
 6616|  5.73k|    if (filename_len < name_len)
  ------------------
  |  Branch (6616:9): [True: 435, False: 5.30k]
  ------------------
 6617|    435|      continue;
 6618|  5.30k|    if (comment_len) {
  ------------------
  |  Branch (6618:9): [True: 0, False: 5.30k]
  ------------------
 6619|      0|      mz_uint file_extra_len = MZ_READ_LE16(pHeader + MZ_ZIP_CDH_EXTRA_LEN_OFS),
  ------------------
  |  |  769|      0|  ((mz_uint32)(((const mz_uint8 *)(p))[0]) |                                   \
  |  |  770|      0|   ((mz_uint32)(((const mz_uint8 *)(p))[1]) << 8U))
  ------------------
 6620|      0|              file_comment_len =
 6621|      0|                  MZ_READ_LE16(pHeader + MZ_ZIP_CDH_COMMENT_LEN_OFS);
  ------------------
  |  |  769|      0|  ((mz_uint32)(((const mz_uint8 *)(p))[0]) |                                   \
  |  |  770|      0|   ((mz_uint32)(((const mz_uint8 *)(p))[1]) << 8U))
  ------------------
 6622|      0|      const char *pFile_comment = pFilename + filename_len + file_extra_len;
 6623|      0|      if ((file_comment_len != comment_len) ||
  ------------------
  |  Branch (6623:11): [True: 0, False: 0]
  ------------------
 6624|      0|          (!mz_zip_string_equal(pComment, pFile_comment, file_comment_len,
  ------------------
  |  Branch (6624:11): [True: 0, False: 0]
  ------------------
 6625|      0|                                flags)))
 6626|      0|        continue;
 6627|      0|    }
 6628|  5.30k|    if ((flags & MZ_ZIP_FLAG_IGNORE_PATH) && (filename_len)) {
  ------------------
  |  Branch (6628:9): [True: 0, False: 5.30k]
  |  Branch (6628:46): [True: 0, False: 0]
  ------------------
 6629|      0|      int ofs = filename_len - 1;
 6630|      0|      do {
 6631|      0|        if ((pFilename[ofs] == '/') || (pFilename[ofs] == '\\') ||
  ------------------
  |  Branch (6631:13): [True: 0, False: 0]
  |  Branch (6631:40): [True: 0, False: 0]
  ------------------
 6632|      0|            (pFilename[ofs] == ':'))
  ------------------
  |  Branch (6632:13): [True: 0, False: 0]
  ------------------
 6633|      0|          break;
 6634|      0|      } while (--ofs >= 0);
  ------------------
  |  Branch (6634:16): [True: 0, False: 0]
  ------------------
 6635|      0|      ofs++;
 6636|      0|      pFilename += ofs;
 6637|      0|      filename_len -= ofs;
 6638|      0|    }
 6639|  5.30k|    if ((filename_len == name_len) &&
  ------------------
  |  Branch (6639:9): [True: 2.96k, False: 2.33k]
  ------------------
 6640|  2.96k|        (mz_zip_string_equal(pName, pFilename, filename_len, flags))) {
  ------------------
  |  Branch (6640:9): [True: 2.51k, False: 449]
  ------------------
 6641|  2.51k|      if (pIndex)
  ------------------
  |  Branch (6641:11): [True: 2.51k, False: 0]
  ------------------
 6642|  2.51k|        *pIndex = file_index;
 6643|  2.51k|      return MZ_TRUE;
  ------------------
  |  |  719|  2.51k|#define MZ_TRUE (1)
  ------------------
 6644|  2.51k|    }
 6645|  5.30k|  }
 6646|       |
 6647|    548|  return mz_zip_set_error(pZip, MZ_ZIP_FILE_NOT_FOUND);
 6648|  3.06k|}
mz_zip_reader_extract_to_mem_no_alloc:
 6814|  1.57k|                                              size_t user_read_buf_size) {
 6815|  1.57k|  return mz_zip_reader_extract_to_mem_no_alloc1(pZip, file_index, pBuf,
 6816|  1.57k|                                                buf_size, flags, pUser_read_buf,
 6817|       |                                                user_read_buf_size, NULL);
 6818|  1.57k|}
mz_zip_reader_file_stat:
10220|  7.99k|                                mz_zip_archive_file_stat *pStat) {
10221|  7.99k|  return mz_zip_file_stat_internal(
10222|       |      pZip, file_index, mz_zip_get_cdh(pZip, file_index), pStat, NULL);
10223|  7.99k|}
zip.c:tinfl_clear_tree:
 4375|  3.19k|static void tinfl_clear_tree(tinfl_decompressor *r) {
 4376|  3.19k|  if (r->m_type == 0)
  ------------------
  |  Branch (4376:7): [True: 1.40k, False: 1.79k]
  ------------------
 4377|  1.40k|    MZ_CLEAR_ARR(r->m_tree_0);
  ------------------
  |  |  761|  1.40k|#define MZ_CLEAR_ARR(obj) memset((obj), 0, sizeof(obj))
  ------------------
 4378|  1.79k|  else if (r->m_type == 1)
  ------------------
  |  Branch (4378:12): [True: 1.40k, False: 393]
  ------------------
 4379|  1.40k|    MZ_CLEAR_ARR(r->m_tree_1);
  ------------------
  |  |  761|  1.40k|#define MZ_CLEAR_ARR(obj) memset((obj), 0, sizeof(obj))
  ------------------
 4380|    393|  else
 4381|    393|    MZ_CLEAR_ARR(r->m_tree_2);
  ------------------
  |  |  761|    393|#define MZ_CLEAR_ARR(obj) memset((obj), 0, sizeof(obj))
  ------------------
 4382|  3.19k|}
zip.c:mz_zip_reader_end_internal:
 6052|  3.82k|                                          mz_bool set_last_error) {
 6053|  3.82k|  mz_bool status = MZ_TRUE;
  ------------------
  |  |  719|  3.82k|#define MZ_TRUE (1)
  ------------------
 6054|       |
 6055|  3.82k|  if (!pZip)
  ------------------
  |  Branch (6055:7): [True: 0, False: 3.82k]
  ------------------
 6056|      0|    return MZ_FALSE;
  ------------------
  |  |  718|      0|#define MZ_FALSE (0)
  ------------------
 6057|       |
 6058|  3.82k|  if ((!pZip->m_pState) || (!pZip->m_pAlloc) || (!pZip->m_pFree) ||
  ------------------
  |  Branch (6058:7): [True: 0, False: 3.82k]
  |  Branch (6058:28): [True: 0, False: 3.82k]
  |  Branch (6058:49): [True: 0, False: 3.82k]
  ------------------
 6059|  3.82k|      (pZip->m_zip_mode != MZ_ZIP_MODE_READING)) {
  ------------------
  |  Branch (6059:7): [True: 0, False: 3.82k]
  ------------------
 6060|      0|    if (set_last_error)
  ------------------
  |  Branch (6060:9): [True: 0, False: 0]
  ------------------
 6061|      0|      pZip->m_last_error = MZ_ZIP_INVALID_PARAMETER;
 6062|       |
 6063|      0|    return MZ_FALSE;
  ------------------
  |  |  718|      0|#define MZ_FALSE (0)
  ------------------
 6064|      0|  }
 6065|       |
 6066|  3.82k|  if (pZip->m_pState) {
  ------------------
  |  Branch (6066:7): [True: 3.82k, False: 0]
  ------------------
 6067|  3.82k|    mz_zip_internal_state *pState = pZip->m_pState;
 6068|  3.82k|    pZip->m_pState = NULL;
 6069|       |
 6070|  3.82k|    mz_zip_array_clear(pZip, &pState->m_central_dir);
 6071|  3.82k|    mz_zip_array_clear(pZip, &pState->m_central_dir_offsets);
 6072|  3.82k|    mz_zip_array_clear(pZip, &pState->m_sorted_central_dir_offsets);
 6073|       |
 6074|  3.82k|#ifndef MINIZ_NO_STDIO
 6075|  3.82k|    if (pState->m_pFile) {
  ------------------
  |  Branch (6075:9): [True: 0, False: 3.82k]
  ------------------
 6076|      0|      if (pZip->m_zip_type == MZ_ZIP_TYPE_FILE) {
  ------------------
  |  Branch (6076:11): [True: 0, False: 0]
  ------------------
 6077|      0|        if (MZ_FCLOSE(pState->m_pFile) == EOF) {
  ------------------
  |  | 5173|      0|#define MZ_FCLOSE fclose
  ------------------
  |  Branch (6077:13): [True: 0, False: 0]
  ------------------
 6078|      0|          if (set_last_error)
  ------------------
  |  Branch (6078:15): [True: 0, False: 0]
  ------------------
 6079|      0|            pZip->m_last_error = MZ_ZIP_FILE_CLOSE_FAILED;
 6080|      0|          status = MZ_FALSE;
  ------------------
  |  |  718|      0|#define MZ_FALSE (0)
  ------------------
 6081|      0|        }
 6082|      0|      }
 6083|      0|      pState->m_pFile = NULL;
 6084|      0|    }
 6085|  3.82k|#endif /* #ifndef MINIZ_NO_STDIO */
 6086|       |
 6087|  3.82k|    pZip->m_pFree(pZip->m_pAlloc_opaque, pState);
 6088|  3.82k|  }
 6089|  3.82k|  pZip->m_zip_mode = MZ_ZIP_MODE_INVALID;
 6090|       |
 6091|  3.82k|  return status;
 6092|  3.82k|}
zip.c:mz_zip_set_error:
 5503|  6.16k|                                               mz_zip_error err_num) {
 5504|  6.16k|  if (pZip)
  ------------------
  |  Branch (5504:7): [True: 6.16k, False: 0]
  ------------------
 5505|  6.16k|    pZip->m_last_error = err_num;
 5506|  6.16k|  return MZ_FALSE;
  ------------------
  |  |  718|  6.16k|#define MZ_FALSE (0)
  ------------------
 5507|  6.16k|}
zip.c:mz_zip_reader_init_internal:
 5510|  3.82k|                                           mz_uint flags) {
 5511|  3.82k|  (void)flags;
 5512|  3.82k|  if ((!pZip) || (pZip->m_pState) || (pZip->m_zip_mode != MZ_ZIP_MODE_INVALID))
  ------------------
  |  Branch (5512:7): [True: 0, False: 3.82k]
  |  Branch (5512:18): [True: 0, False: 3.82k]
  |  Branch (5512:38): [True: 0, False: 3.82k]
  ------------------
 5513|      0|    return mz_zip_set_error(pZip, MZ_ZIP_INVALID_PARAMETER);
 5514|       |
 5515|  3.82k|  if (!pZip->m_pAlloc)
  ------------------
  |  Branch (5515:7): [True: 3.82k, False: 0]
  ------------------
 5516|  3.82k|    pZip->m_pAlloc = miniz_def_alloc_func;
 5517|  3.82k|  if (!pZip->m_pFree)
  ------------------
  |  Branch (5517:7): [True: 3.82k, False: 0]
  ------------------
 5518|  3.82k|    pZip->m_pFree = miniz_def_free_func;
 5519|  3.82k|  if (!pZip->m_pRealloc)
  ------------------
  |  Branch (5519:7): [True: 3.82k, False: 0]
  ------------------
 5520|  3.82k|    pZip->m_pRealloc = miniz_def_realloc_func;
 5521|       |
 5522|  3.82k|  pZip->m_archive_size = 0;
 5523|  3.82k|  pZip->m_central_directory_file_ofs = 0;
 5524|  3.82k|  pZip->m_total_files = 0;
 5525|  3.82k|  pZip->m_last_error = MZ_ZIP_NO_ERROR;
 5526|       |
 5527|  3.82k|  if (NULL == (pZip->m_pState = (mz_zip_internal_state *)pZip->m_pAlloc(
  ------------------
  |  Branch (5527:7): [True: 0, False: 3.82k]
  ------------------
 5528|  3.82k|                   pZip->m_pAlloc_opaque, 1, sizeof(mz_zip_internal_state))))
 5529|      0|    return mz_zip_set_error(pZip, MZ_ZIP_ALLOC_FAILED);
 5530|       |
 5531|  3.82k|  memset(pZip->m_pState, 0, sizeof(mz_zip_internal_state));
 5532|  3.82k|  MZ_ZIP_ARRAY_SET_ELEMENT_SIZE(&pZip->m_pState->m_central_dir,
  ------------------
  |  | 5342|  3.82k|  (array_ptr)->m_element_size = element_size
  ------------------
 5533|  3.82k|                                sizeof(mz_uint8));
 5534|  3.82k|  MZ_ZIP_ARRAY_SET_ELEMENT_SIZE(&pZip->m_pState->m_central_dir_offsets,
  ------------------
  |  | 5342|  3.82k|  (array_ptr)->m_element_size = element_size
  ------------------
 5535|  3.82k|                                sizeof(mz_uint32));
 5536|  3.82k|  MZ_ZIP_ARRAY_SET_ELEMENT_SIZE(&pZip->m_pState->m_sorted_central_dir_offsets,
  ------------------
  |  | 5342|  3.82k|  (array_ptr)->m_element_size = element_size
  ------------------
 5537|  3.82k|                                sizeof(mz_uint32));
 5538|  3.82k|  pZip->m_pState->m_init_flags = flags;
 5539|  3.82k|  pZip->m_pState->m_zip64 = MZ_FALSE;
  ------------------
  |  |  718|  3.82k|#define MZ_FALSE (0)
  ------------------
 5540|  3.82k|  pZip->m_pState->m_zip64_has_extended_info_fields = MZ_FALSE;
  ------------------
  |  |  718|  3.82k|#define MZ_FALSE (0)
  ------------------
 5541|       |
 5542|  3.82k|  pZip->m_zip_mode = MZ_ZIP_MODE_READING;
 5543|       |
 5544|  3.82k|  return MZ_TRUE;
  ------------------
  |  |  719|  3.82k|#define MZ_TRUE (1)
  ------------------
 5545|  3.82k|}
zip.c:mz_zip_reader_read_central_dir:
 5705|  3.82k|                                              mz_uint flags) {
 5706|  3.82k|  mz_uint cdir_size = 0, cdir_entries_on_this_disk = 0, num_this_disk = 0,
 5707|  3.82k|          cdir_disk_index = 0;
 5708|  3.82k|  mz_uint64 cdir_ofs = 0, eocd_ofs = 0, archive_ofs = 0;
 5709|  3.82k|  mz_int64 cur_file_ofs = 0;
 5710|  3.82k|  const mz_uint8 *p;
 5711|       |
 5712|  3.82k|  mz_uint32 buf_u32[4096 / sizeof(mz_uint32)];
 5713|  3.82k|  mz_uint8 *pBuf = (mz_uint8 *)buf_u32;
 5714|  3.82k|  mz_bool sort_central_dir =
 5715|  3.82k|      ((flags & MZ_ZIP_FLAG_DO_NOT_SORT_CENTRAL_DIRECTORY) == 0);
 5716|  3.82k|  mz_uint32 zip64_end_of_central_dir_locator_u32
 5717|  3.82k|      [(MZ_ZIP64_END_OF_CENTRAL_DIR_LOCATOR_SIZE + sizeof(mz_uint32) - 1) /
 5718|  3.82k|       sizeof(mz_uint32)];
 5719|  3.82k|  mz_uint8 *pZip64_locator = (mz_uint8 *)zip64_end_of_central_dir_locator_u32;
 5720|       |
 5721|  3.82k|  mz_uint32 zip64_end_of_central_dir_header_u32
 5722|  3.82k|      [(MZ_ZIP64_END_OF_CENTRAL_DIR_HEADER_SIZE + sizeof(mz_uint32) - 1) /
 5723|  3.82k|       sizeof(mz_uint32)];
 5724|  3.82k|  mz_uint8 *pZip64_end_of_central_dir =
 5725|  3.82k|      (mz_uint8 *)zip64_end_of_central_dir_header_u32;
 5726|       |
 5727|  3.82k|  mz_uint64 zip64_end_of_central_dir_ofs = 0;
 5728|       |
 5729|       |  /* Basic sanity checks - reject files which are too small, and check the first
 5730|       |   * 4 bytes of the file to make sure a local header is there. */
 5731|  3.82k|  if (pZip->m_archive_size < MZ_ZIP_END_OF_CENTRAL_DIR_HEADER_SIZE)
  ------------------
  |  Branch (5731:7): [True: 0, False: 3.82k]
  ------------------
 5732|      0|    return mz_zip_set_error(pZip, MZ_ZIP_NOT_AN_ARCHIVE);
 5733|       |
 5734|  3.82k|  if (!mz_zip_reader_locate_header_sig(
  ------------------
  |  Branch (5734:7): [True: 59, False: 3.76k]
  ------------------
 5735|  3.82k|          pZip, MZ_ZIP_END_OF_CENTRAL_DIR_HEADER_SIG,
 5736|  3.82k|          MZ_ZIP_END_OF_CENTRAL_DIR_HEADER_SIZE, &cur_file_ofs))
 5737|     59|    return mz_zip_set_error(pZip, MZ_ZIP_FAILED_FINDING_CENTRAL_DIR);
 5738|       |
 5739|  3.76k|  eocd_ofs = cur_file_ofs;
 5740|       |  /* Read and verify the end of central directory record. */
 5741|  3.76k|  if (pZip->m_pRead(pZip->m_pIO_opaque, cur_file_ofs, pBuf,
  ------------------
  |  Branch (5741:7): [True: 0, False: 3.76k]
  ------------------
 5742|  3.76k|                    MZ_ZIP_END_OF_CENTRAL_DIR_HEADER_SIZE) !=
 5743|  3.76k|      MZ_ZIP_END_OF_CENTRAL_DIR_HEADER_SIZE)
 5744|      0|    return mz_zip_set_error(pZip, MZ_ZIP_FILE_READ_FAILED);
 5745|       |
 5746|  3.76k|  if (MZ_READ_LE32(pBuf + MZ_ZIP_ECDH_SIG_OFS) !=
  ------------------
  |  |  772|  3.76k|  ((mz_uint32)(((const mz_uint8 *)(p))[0]) |                                   \
  |  |  773|  3.76k|   ((mz_uint32)(((const mz_uint8 *)(p))[1]) << 8U) |                           \
  |  |  774|  3.76k|   ((mz_uint32)(((const mz_uint8 *)(p))[2]) << 16U) |                          \
  |  |  775|  3.76k|   ((mz_uint32)(((const mz_uint8 *)(p))[3]) << 24U))
  ------------------
  |  Branch (5746:7): [True: 0, False: 3.76k]
  ------------------
 5747|  3.76k|      MZ_ZIP_END_OF_CENTRAL_DIR_HEADER_SIG)
 5748|      0|    return mz_zip_set_error(pZip, MZ_ZIP_NOT_AN_ARCHIVE);
 5749|       |
 5750|  3.76k|  if (cur_file_ofs >= (MZ_ZIP64_END_OF_CENTRAL_DIR_LOCATOR_SIZE +
  ------------------
  |  Branch (5750:7): [True: 2.16k, False: 1.59k]
  ------------------
 5751|  3.76k|                       MZ_ZIP64_END_OF_CENTRAL_DIR_HEADER_SIZE)) {
 5752|  2.16k|    if (pZip->m_pRead(pZip->m_pIO_opaque,
  ------------------
  |  Branch (5752:9): [True: 2.16k, False: 0]
  ------------------
 5753|  2.16k|                      cur_file_ofs - MZ_ZIP64_END_OF_CENTRAL_DIR_LOCATOR_SIZE,
 5754|  2.16k|                      pZip64_locator,
 5755|  2.16k|                      MZ_ZIP64_END_OF_CENTRAL_DIR_LOCATOR_SIZE) ==
 5756|  2.16k|        MZ_ZIP64_END_OF_CENTRAL_DIR_LOCATOR_SIZE) {
 5757|  2.16k|      if (MZ_READ_LE32(pZip64_locator + MZ_ZIP64_ECDL_SIG_OFS) ==
  ------------------
  |  |  772|  2.16k|  ((mz_uint32)(((const mz_uint8 *)(p))[0]) |                                   \
  |  |  773|  2.16k|   ((mz_uint32)(((const mz_uint8 *)(p))[1]) << 8U) |                           \
  |  |  774|  2.16k|   ((mz_uint32)(((const mz_uint8 *)(p))[2]) << 16U) |                          \
  |  |  775|  2.16k|   ((mz_uint32)(((const mz_uint8 *)(p))[3]) << 24U))
  ------------------
  |  Branch (5757:11): [True: 615, False: 1.55k]
  ------------------
 5758|  2.16k|          MZ_ZIP64_END_OF_CENTRAL_DIR_LOCATOR_SIG) {
 5759|    615|        pZip->m_pState->m_zip64 = MZ_TRUE;
  ------------------
  |  |  719|    615|#define MZ_TRUE (1)
  ------------------
 5760|    615|      }
 5761|  2.16k|    }
 5762|  2.16k|  }
 5763|       |
 5764|  3.76k|  if (pZip->m_pState->m_zip64) {
  ------------------
  |  Branch (5764:7): [True: 615, False: 3.14k]
  ------------------
 5765|       |    /* Try locating the EOCD64 right before the EOCD64 locator. This works even
 5766|       |     * when the effective start of the zip header is not yet known. */
 5767|    615|    if (cur_file_ofs < MZ_ZIP64_END_OF_CENTRAL_DIR_LOCATOR_SIZE +
  ------------------
  |  Branch (5767:9): [True: 0, False: 615]
  ------------------
 5768|    615|                           MZ_ZIP64_END_OF_CENTRAL_DIR_HEADER_SIZE)
 5769|      0|      return mz_zip_set_error(pZip, MZ_ZIP_NOT_AN_ARCHIVE);
 5770|       |
 5771|    615|    zip64_end_of_central_dir_ofs = cur_file_ofs -
 5772|    615|                                   MZ_ZIP64_END_OF_CENTRAL_DIR_LOCATOR_SIZE -
 5773|    615|                                   MZ_ZIP64_END_OF_CENTRAL_DIR_HEADER_SIZE;
 5774|       |
 5775|    615|    if (!mz_zip_reader_eocd64_valid(pZip, zip64_end_of_central_dir_ofs,
  ------------------
  |  Branch (5775:9): [True: 372, False: 243]
  ------------------
 5776|    615|                                    pZip64_end_of_central_dir)) {
 5777|       |      /* That failed, try reading where the locator tells us to. */
 5778|    372|      zip64_end_of_central_dir_ofs = MZ_READ_LE64(
  ------------------
  |  |  779|    372|  (((mz_uint64)MZ_READ_LE32(p)) |                                              \
  |  |  ------------------
  |  |  |  |  772|    372|  ((mz_uint32)(((const mz_uint8 *)(p))[0]) |                                   \
  |  |  |  |  773|    372|   ((mz_uint32)(((const mz_uint8 *)(p))[1]) << 8U) |                           \
  |  |  |  |  774|    372|   ((mz_uint32)(((const mz_uint8 *)(p))[2]) << 16U) |                          \
  |  |  |  |  775|    372|   ((mz_uint32)(((const mz_uint8 *)(p))[3]) << 24U))
  |  |  ------------------
  |  |  780|    372|   (((mz_uint64)MZ_READ_LE32((const mz_uint8 *)(p) + sizeof(mz_uint32)))       \
  |  |  ------------------
  |  |  |  |  772|    372|  ((mz_uint32)(((const mz_uint8 *)(p))[0]) |                                   \
  |  |  |  |  773|    372|   ((mz_uint32)(((const mz_uint8 *)(p))[1]) << 8U) |                           \
  |  |  |  |  774|    372|   ((mz_uint32)(((const mz_uint8 *)(p))[2]) << 16U) |                          \
  |  |  |  |  775|    372|   ((mz_uint32)(((const mz_uint8 *)(p))[3]) << 24U))
  |  |  ------------------
  |  |  781|    372|    << 32U))
  ------------------
 5779|    372|          pZip64_locator + MZ_ZIP64_ECDL_REL_OFS_TO_ZIP64_ECDR_OFS);
 5780|       |
 5781|    372|      if (zip64_end_of_central_dir_ofs >
  ------------------
  |  Branch (5781:11): [True: 110, False: 262]
  ------------------
 5782|    372|          (pZip->m_archive_size - MZ_ZIP64_END_OF_CENTRAL_DIR_HEADER_SIZE))
 5783|    110|        return mz_zip_set_error(pZip, MZ_ZIP_NOT_AN_ARCHIVE);
 5784|       |
 5785|    262|      if (!mz_zip_reader_eocd64_valid(pZip, zip64_end_of_central_dir_ofs,
  ------------------
  |  Branch (5785:11): [True: 55, False: 207]
  ------------------
 5786|    262|                                      pZip64_end_of_central_dir))
 5787|     55|        return mz_zip_set_error(pZip, MZ_ZIP_NOT_AN_ARCHIVE);
 5788|    262|    }
 5789|    615|  }
 5790|       |
 5791|  3.59k|  pZip->m_total_files = MZ_READ_LE16(pBuf + MZ_ZIP_ECDH_CDIR_TOTAL_ENTRIES_OFS);
  ------------------
  |  |  769|  3.59k|  ((mz_uint32)(((const mz_uint8 *)(p))[0]) |                                   \
  |  |  770|  3.59k|   ((mz_uint32)(((const mz_uint8 *)(p))[1]) << 8U))
  ------------------
 5792|  3.59k|  cdir_entries_on_this_disk =
 5793|  3.59k|      MZ_READ_LE16(pBuf + MZ_ZIP_ECDH_CDIR_NUM_ENTRIES_ON_DISK_OFS);
  ------------------
  |  |  769|  3.59k|  ((mz_uint32)(((const mz_uint8 *)(p))[0]) |                                   \
  |  |  770|  3.59k|   ((mz_uint32)(((const mz_uint8 *)(p))[1]) << 8U))
  ------------------
 5794|  3.59k|  num_this_disk = MZ_READ_LE16(pBuf + MZ_ZIP_ECDH_NUM_THIS_DISK_OFS);
  ------------------
  |  |  769|  3.59k|  ((mz_uint32)(((const mz_uint8 *)(p))[0]) |                                   \
  |  |  770|  3.59k|   ((mz_uint32)(((const mz_uint8 *)(p))[1]) << 8U))
  ------------------
 5795|  3.59k|  cdir_disk_index = MZ_READ_LE16(pBuf + MZ_ZIP_ECDH_NUM_DISK_CDIR_OFS);
  ------------------
  |  |  769|  3.59k|  ((mz_uint32)(((const mz_uint8 *)(p))[0]) |                                   \
  |  |  770|  3.59k|   ((mz_uint32)(((const mz_uint8 *)(p))[1]) << 8U))
  ------------------
 5796|  3.59k|  cdir_size = MZ_READ_LE32(pBuf + MZ_ZIP_ECDH_CDIR_SIZE_OFS);
  ------------------
  |  |  772|  3.59k|  ((mz_uint32)(((const mz_uint8 *)(p))[0]) |                                   \
  |  |  773|  3.59k|   ((mz_uint32)(((const mz_uint8 *)(p))[1]) << 8U) |                           \
  |  |  774|  3.59k|   ((mz_uint32)(((const mz_uint8 *)(p))[2]) << 16U) |                          \
  |  |  775|  3.59k|   ((mz_uint32)(((const mz_uint8 *)(p))[3]) << 24U))
  ------------------
 5797|  3.59k|  cdir_ofs = MZ_READ_LE32(pBuf + MZ_ZIP_ECDH_CDIR_OFS_OFS);
  ------------------
  |  |  772|  3.59k|  ((mz_uint32)(((const mz_uint8 *)(p))[0]) |                                   \
  |  |  773|  3.59k|   ((mz_uint32)(((const mz_uint8 *)(p))[1]) << 8U) |                           \
  |  |  774|  3.59k|   ((mz_uint32)(((const mz_uint8 *)(p))[2]) << 16U) |                          \
  |  |  775|  3.59k|   ((mz_uint32)(((const mz_uint8 *)(p))[3]) << 24U))
  ------------------
 5798|       |
 5799|  3.59k|  if (pZip->m_pState->m_zip64) {
  ------------------
  |  Branch (5799:7): [True: 450, False: 3.14k]
  ------------------
 5800|    450|    mz_uint32 zip64_total_num_of_disks =
 5801|    450|        MZ_READ_LE32(pZip64_locator + MZ_ZIP64_ECDL_TOTAL_NUMBER_OF_DISKS_OFS);
  ------------------
  |  |  772|    450|  ((mz_uint32)(((const mz_uint8 *)(p))[0]) |                                   \
  |  |  773|    450|   ((mz_uint32)(((const mz_uint8 *)(p))[1]) << 8U) |                           \
  |  |  774|    450|   ((mz_uint32)(((const mz_uint8 *)(p))[2]) << 16U) |                          \
  |  |  775|    450|   ((mz_uint32)(((const mz_uint8 *)(p))[3]) << 24U))
  ------------------
 5802|    450|    mz_uint64 zip64_cdir_total_entries = MZ_READ_LE64(
  ------------------
  |  |  779|    450|  (((mz_uint64)MZ_READ_LE32(p)) |                                              \
  |  |  ------------------
  |  |  |  |  772|    450|  ((mz_uint32)(((const mz_uint8 *)(p))[0]) |                                   \
  |  |  |  |  773|    450|   ((mz_uint32)(((const mz_uint8 *)(p))[1]) << 8U) |                           \
  |  |  |  |  774|    450|   ((mz_uint32)(((const mz_uint8 *)(p))[2]) << 16U) |                          \
  |  |  |  |  775|    450|   ((mz_uint32)(((const mz_uint8 *)(p))[3]) << 24U))
  |  |  ------------------
  |  |  780|    450|   (((mz_uint64)MZ_READ_LE32((const mz_uint8 *)(p) + sizeof(mz_uint32)))       \
  |  |  ------------------
  |  |  |  |  772|    450|  ((mz_uint32)(((const mz_uint8 *)(p))[0]) |                                   \
  |  |  |  |  773|    450|   ((mz_uint32)(((const mz_uint8 *)(p))[1]) << 8U) |                           \
  |  |  |  |  774|    450|   ((mz_uint32)(((const mz_uint8 *)(p))[2]) << 16U) |                          \
  |  |  |  |  775|    450|   ((mz_uint32)(((const mz_uint8 *)(p))[3]) << 24U))
  |  |  ------------------
  |  |  781|    450|    << 32U))
  ------------------
 5803|    450|        pZip64_end_of_central_dir + MZ_ZIP64_ECDH_CDIR_TOTAL_ENTRIES_OFS);
 5804|    450|    mz_uint64 zip64_cdir_total_entries_on_this_disk = MZ_READ_LE64(
  ------------------
  |  |  779|    450|  (((mz_uint64)MZ_READ_LE32(p)) |                                              \
  |  |  ------------------
  |  |  |  |  772|    450|  ((mz_uint32)(((const mz_uint8 *)(p))[0]) |                                   \
  |  |  |  |  773|    450|   ((mz_uint32)(((const mz_uint8 *)(p))[1]) << 8U) |                           \
  |  |  |  |  774|    450|   ((mz_uint32)(((const mz_uint8 *)(p))[2]) << 16U) |                          \
  |  |  |  |  775|    450|   ((mz_uint32)(((const mz_uint8 *)(p))[3]) << 24U))
  |  |  ------------------
  |  |  780|    450|   (((mz_uint64)MZ_READ_LE32((const mz_uint8 *)(p) + sizeof(mz_uint32)))       \
  |  |  ------------------
  |  |  |  |  772|    450|  ((mz_uint32)(((const mz_uint8 *)(p))[0]) |                                   \
  |  |  |  |  773|    450|   ((mz_uint32)(((const mz_uint8 *)(p))[1]) << 8U) |                           \
  |  |  |  |  774|    450|   ((mz_uint32)(((const mz_uint8 *)(p))[2]) << 16U) |                          \
  |  |  |  |  775|    450|   ((mz_uint32)(((const mz_uint8 *)(p))[3]) << 24U))
  |  |  ------------------
  |  |  781|    450|    << 32U))
  ------------------
 5805|    450|        pZip64_end_of_central_dir + MZ_ZIP64_ECDH_CDIR_NUM_ENTRIES_ON_DISK_OFS);
 5806|    450|    mz_uint64 zip64_size_of_end_of_central_dir_record = MZ_READ_LE64(
  ------------------
  |  |  779|    450|  (((mz_uint64)MZ_READ_LE32(p)) |                                              \
  |  |  ------------------
  |  |  |  |  772|    450|  ((mz_uint32)(((const mz_uint8 *)(p))[0]) |                                   \
  |  |  |  |  773|    450|   ((mz_uint32)(((const mz_uint8 *)(p))[1]) << 8U) |                           \
  |  |  |  |  774|    450|   ((mz_uint32)(((const mz_uint8 *)(p))[2]) << 16U) |                          \
  |  |  |  |  775|    450|   ((mz_uint32)(((const mz_uint8 *)(p))[3]) << 24U))
  |  |  ------------------
  |  |  780|    450|   (((mz_uint64)MZ_READ_LE32((const mz_uint8 *)(p) + sizeof(mz_uint32)))       \
  |  |  ------------------
  |  |  |  |  772|    450|  ((mz_uint32)(((const mz_uint8 *)(p))[0]) |                                   \
  |  |  |  |  773|    450|   ((mz_uint32)(((const mz_uint8 *)(p))[1]) << 8U) |                           \
  |  |  |  |  774|    450|   ((mz_uint32)(((const mz_uint8 *)(p))[2]) << 16U) |                          \
  |  |  |  |  775|    450|   ((mz_uint32)(((const mz_uint8 *)(p))[3]) << 24U))
  |  |  ------------------
  |  |  781|    450|    << 32U))
  ------------------
 5807|    450|        pZip64_end_of_central_dir + MZ_ZIP64_ECDH_SIZE_OF_RECORD_OFS);
 5808|    450|    mz_uint64 zip64_size_of_central_directory =
 5809|    450|        MZ_READ_LE64(pZip64_end_of_central_dir + MZ_ZIP64_ECDH_CDIR_SIZE_OFS);
  ------------------
  |  |  779|    450|  (((mz_uint64)MZ_READ_LE32(p)) |                                              \
  |  |  ------------------
  |  |  |  |  772|    450|  ((mz_uint32)(((const mz_uint8 *)(p))[0]) |                                   \
  |  |  |  |  773|    450|   ((mz_uint32)(((const mz_uint8 *)(p))[1]) << 8U) |                           \
  |  |  |  |  774|    450|   ((mz_uint32)(((const mz_uint8 *)(p))[2]) << 16U) |                          \
  |  |  |  |  775|    450|   ((mz_uint32)(((const mz_uint8 *)(p))[3]) << 24U))
  |  |  ------------------
  |  |  780|    450|   (((mz_uint64)MZ_READ_LE32((const mz_uint8 *)(p) + sizeof(mz_uint32)))       \
  |  |  ------------------
  |  |  |  |  772|    450|  ((mz_uint32)(((const mz_uint8 *)(p))[0]) |                                   \
  |  |  |  |  773|    450|   ((mz_uint32)(((const mz_uint8 *)(p))[1]) << 8U) |                           \
  |  |  |  |  774|    450|   ((mz_uint32)(((const mz_uint8 *)(p))[2]) << 16U) |                          \
  |  |  |  |  775|    450|   ((mz_uint32)(((const mz_uint8 *)(p))[3]) << 24U))
  |  |  ------------------
  |  |  781|    450|    << 32U))
  ------------------
 5810|       |
 5811|    450|    if (zip64_size_of_end_of_central_dir_record <
  ------------------
  |  Branch (5811:9): [True: 4, False: 446]
  ------------------
 5812|    450|        (MZ_ZIP64_END_OF_CENTRAL_DIR_HEADER_SIZE - 12))
 5813|      4|      return mz_zip_set_error(pZip, MZ_ZIP_INVALID_HEADER_OR_CORRUPTED);
 5814|       |
 5815|    446|    if (zip64_total_num_of_disks != 1U)
  ------------------
  |  Branch (5815:9): [True: 52, False: 394]
  ------------------
 5816|     52|      return mz_zip_set_error(pZip, MZ_ZIP_UNSUPPORTED_MULTIDISK);
 5817|       |
 5818|       |    /* Check for miniz's practical limits */
 5819|    394|    if (zip64_cdir_total_entries > MZ_UINT32_MAX)
  ------------------
  |  |  794|    394|#define MZ_UINT32_MAX (0xFFFFFFFFU)
  ------------------
  |  Branch (5819:9): [True: 53, False: 341]
  ------------------
 5820|     53|      return mz_zip_set_error(pZip, MZ_ZIP_TOO_MANY_FILES);
 5821|       |
 5822|    341|    pZip->m_total_files = (mz_uint32)zip64_cdir_total_entries;
 5823|       |
 5824|    341|    if (zip64_cdir_total_entries_on_this_disk > MZ_UINT32_MAX)
  ------------------
  |  |  794|    341|#define MZ_UINT32_MAX (0xFFFFFFFFU)
  ------------------
  |  Branch (5824:9): [True: 50, False: 291]
  ------------------
 5825|     50|      return mz_zip_set_error(pZip, MZ_ZIP_TOO_MANY_FILES);
 5826|       |
 5827|    291|    cdir_entries_on_this_disk =
 5828|    291|        (mz_uint32)zip64_cdir_total_entries_on_this_disk;
 5829|       |
 5830|       |    /* Check for miniz's current practical limits (sorry, this should be enough
 5831|       |     * for millions of files) */
 5832|    291|    if (zip64_size_of_central_directory > MZ_UINT32_MAX)
  ------------------
  |  |  794|    291|#define MZ_UINT32_MAX (0xFFFFFFFFU)
  ------------------
  |  Branch (5832:9): [True: 43, False: 248]
  ------------------
 5833|     43|      return mz_zip_set_error(pZip, MZ_ZIP_UNSUPPORTED_CDIR_SIZE);
 5834|       |
 5835|    248|    cdir_size = (mz_uint32)zip64_size_of_central_directory;
 5836|       |
 5837|    248|    num_this_disk = MZ_READ_LE32(pZip64_end_of_central_dir +
  ------------------
  |  |  772|    248|  ((mz_uint32)(((const mz_uint8 *)(p))[0]) |                                   \
  |  |  773|    248|   ((mz_uint32)(((const mz_uint8 *)(p))[1]) << 8U) |                           \
  |  |  774|    248|   ((mz_uint32)(((const mz_uint8 *)(p))[2]) << 16U) |                          \
  |  |  775|    248|   ((mz_uint32)(((const mz_uint8 *)(p))[3]) << 24U))
  ------------------
 5838|    248|                                 MZ_ZIP64_ECDH_NUM_THIS_DISK_OFS);
 5839|       |
 5840|    248|    cdir_disk_index = MZ_READ_LE32(pZip64_end_of_central_dir +
  ------------------
  |  |  772|    248|  ((mz_uint32)(((const mz_uint8 *)(p))[0]) |                                   \
  |  |  773|    248|   ((mz_uint32)(((const mz_uint8 *)(p))[1]) << 8U) |                           \
  |  |  774|    248|   ((mz_uint32)(((const mz_uint8 *)(p))[2]) << 16U) |                          \
  |  |  775|    248|   ((mz_uint32)(((const mz_uint8 *)(p))[3]) << 24U))
  ------------------
 5841|    248|                                   MZ_ZIP64_ECDH_NUM_DISK_CDIR_OFS);
 5842|       |
 5843|    248|    cdir_ofs =
 5844|    248|        MZ_READ_LE64(pZip64_end_of_central_dir + MZ_ZIP64_ECDH_CDIR_OFS_OFS);
  ------------------
  |  |  779|    248|  (((mz_uint64)MZ_READ_LE32(p)) |                                              \
  |  |  ------------------
  |  |  |  |  772|    248|  ((mz_uint32)(((const mz_uint8 *)(p))[0]) |                                   \
  |  |  |  |  773|    248|   ((mz_uint32)(((const mz_uint8 *)(p))[1]) << 8U) |                           \
  |  |  |  |  774|    248|   ((mz_uint32)(((const mz_uint8 *)(p))[2]) << 16U) |                          \
  |  |  |  |  775|    248|   ((mz_uint32)(((const mz_uint8 *)(p))[3]) << 24U))
  |  |  ------------------
  |  |  780|    248|   (((mz_uint64)MZ_READ_LE32((const mz_uint8 *)(p) + sizeof(mz_uint32)))       \
  |  |  ------------------
  |  |  |  |  772|    248|  ((mz_uint32)(((const mz_uint8 *)(p))[0]) |                                   \
  |  |  |  |  773|    248|   ((mz_uint32)(((const mz_uint8 *)(p))[1]) << 8U) |                           \
  |  |  |  |  774|    248|   ((mz_uint32)(((const mz_uint8 *)(p))[2]) << 16U) |                          \
  |  |  |  |  775|    248|   ((mz_uint32)(((const mz_uint8 *)(p))[3]) << 24U))
  |  |  ------------------
  |  |  781|    248|    << 32U))
  ------------------
 5845|    248|  }
 5846|       |
 5847|  3.39k|  if (pZip->m_total_files != cdir_entries_on_this_disk)
  ------------------
  |  Branch (5847:7): [True: 68, False: 3.32k]
  ------------------
 5848|     68|    return mz_zip_set_error(pZip, MZ_ZIP_UNSUPPORTED_MULTIDISK);
 5849|       |
 5850|  3.32k|  if (((num_this_disk | cdir_disk_index) != 0) &&
  ------------------
  |  Branch (5850:7): [True: 1.29k, False: 2.03k]
  ------------------
 5851|  1.29k|      ((num_this_disk != 1) || (cdir_disk_index != 1)))
  ------------------
  |  Branch (5851:8): [True: 63, False: 1.23k]
  |  Branch (5851:32): [True: 54, False: 1.17k]
  ------------------
 5852|    117|    return mz_zip_set_error(pZip, MZ_ZIP_UNSUPPORTED_MULTIDISK);
 5853|       |
 5854|  3.21k|  if (cdir_size <
  ------------------
  |  Branch (5854:7): [True: 45, False: 3.16k]
  ------------------
 5855|  3.21k|      (mz_uint64)pZip->m_total_files * MZ_ZIP_CENTRAL_DIR_HEADER_SIZE)
 5856|     45|    return mz_zip_set_error(pZip, MZ_ZIP_INVALID_HEADER_OR_CORRUPTED);
 5857|       |
 5858|  3.16k|  if ((cdir_ofs + (mz_uint64)cdir_size) > pZip->m_archive_size)
  ------------------
  |  Branch (5858:7): [True: 129, False: 3.03k]
  ------------------
 5859|    129|    return mz_zip_set_error(pZip, MZ_ZIP_INVALID_HEADER_OR_CORRUPTED);
 5860|       |
 5861|  3.03k|  if (eocd_ofs < cdir_ofs + cdir_size)
  ------------------
  |  Branch (5861:7): [True: 14, False: 3.02k]
  ------------------
 5862|     14|    return mz_zip_set_error(pZip, MZ_ZIP_INVALID_HEADER_OR_CORRUPTED);
 5863|       |
 5864|       |  /* The end of central dir follows the central dir, unless the zip file has
 5865|       |   * some trailing data (e.g. it is appended to an executable file). */
 5866|  3.02k|  archive_ofs = eocd_ofs - (cdir_ofs + cdir_size);
 5867|  3.02k|  if (pZip->m_pState->m_zip64) {
  ------------------
  |  Branch (5867:7): [True: 63, False: 2.96k]
  ------------------
 5868|     63|    if (archive_ofs < MZ_ZIP64_END_OF_CENTRAL_DIR_HEADER_SIZE +
  ------------------
  |  Branch (5868:9): [True: 9, False: 54]
  ------------------
 5869|     63|                          MZ_ZIP64_END_OF_CENTRAL_DIR_LOCATOR_SIZE)
 5870|      9|      return mz_zip_set_error(pZip, MZ_ZIP_INVALID_HEADER_OR_CORRUPTED);
 5871|       |
 5872|     54|    archive_ofs -= MZ_ZIP64_END_OF_CENTRAL_DIR_HEADER_SIZE +
 5873|     54|                   MZ_ZIP64_END_OF_CENTRAL_DIR_LOCATOR_SIZE;
 5874|     54|  }
 5875|       |
 5876|       |  /* Update the archive start position, but only if not specified. */
 5877|  3.01k|  if ((pZip->m_zip_type == MZ_ZIP_TYPE_FILE ||
  ------------------
  |  Branch (5877:8): [True: 0, False: 3.01k]
  ------------------
 5878|  3.01k|       pZip->m_zip_type == MZ_ZIP_TYPE_CFILE ||
  ------------------
  |  Branch (5878:8): [True: 0, False: 3.01k]
  ------------------
 5879|  3.01k|       pZip->m_zip_type == MZ_ZIP_TYPE_USER) &&
  ------------------
  |  Branch (5879:8): [True: 0, False: 3.01k]
  ------------------
 5880|      0|      pZip->m_pState->m_file_archive_start_ofs == 0) {
  ------------------
  |  Branch (5880:7): [True: 0, False: 0]
  ------------------
 5881|      0|    pZip->m_pState->m_file_archive_start_ofs = archive_ofs;
 5882|      0|    pZip->m_archive_size -= archive_ofs;
 5883|      0|  }
 5884|       |
 5885|  3.01k|  pZip->m_central_directory_file_ofs = cdir_ofs;
 5886|       |
 5887|  3.01k|  if (pZip->m_total_files) {
  ------------------
  |  Branch (5887:7): [True: 2.97k, False: 43]
  ------------------
 5888|  2.97k|    mz_uint i, n;
 5889|       |    /* Read the entire central directory into a heap block, and allocate another
 5890|       |     * heap block to hold the unsorted central dir file record offsets, and
 5891|       |     * possibly another to hold the sorted indices. */
 5892|  2.97k|    if ((!mz_zip_array_resize(pZip, &pZip->m_pState->m_central_dir, cdir_size,
  ------------------
  |  Branch (5892:9): [True: 0, False: 2.97k]
  ------------------
 5893|  2.97k|                              MZ_FALSE)) ||
  ------------------
  |  |  718|  2.97k|#define MZ_FALSE (0)
  ------------------
 5894|  2.97k|        (!mz_zip_array_resize(pZip, &pZip->m_pState->m_central_dir_offsets,
  ------------------
  |  Branch (5894:9): [True: 0, False: 2.97k]
  ------------------
 5895|  2.97k|                              pZip->m_total_files, MZ_FALSE)))
  ------------------
  |  |  718|  2.97k|#define MZ_FALSE (0)
  ------------------
 5896|      0|      return mz_zip_set_error(pZip, MZ_ZIP_ALLOC_FAILED);
 5897|       |
 5898|  2.97k|    if (sort_central_dir) {
  ------------------
  |  Branch (5898:9): [True: 2.97k, False: 0]
  ------------------
 5899|  2.97k|      if (!mz_zip_array_resize(pZip,
  ------------------
  |  Branch (5899:11): [True: 0, False: 2.97k]
  ------------------
 5900|  2.97k|                               &pZip->m_pState->m_sorted_central_dir_offsets,
 5901|  2.97k|                               pZip->m_total_files, MZ_FALSE))
  ------------------
  |  |  718|  2.97k|#define MZ_FALSE (0)
  ------------------
 5902|      0|        return mz_zip_set_error(pZip, MZ_ZIP_ALLOC_FAILED);
 5903|  2.97k|    }
 5904|       |
 5905|  2.97k|    if (pZip->m_pRead(pZip->m_pIO_opaque, cdir_ofs,
  ------------------
  |  Branch (5905:9): [True: 23, False: 2.94k]
  ------------------
 5906|  2.97k|                      pZip->m_pState->m_central_dir.m_p,
 5907|  2.97k|                      cdir_size) != cdir_size)
 5908|     23|      return mz_zip_set_error(pZip, MZ_ZIP_FILE_READ_FAILED);
 5909|       |
 5910|       |    /* Now create an index into the central directory file records, do some
 5911|       |     * basic sanity checking on each record */
 5912|  2.94k|    p = (const mz_uint8 *)pZip->m_pState->m_central_dir.m_p;
 5913|  6.96k|    for (n = cdir_size, i = 0; i < pZip->m_total_files; ++i) {
  ------------------
  |  Branch (5913:32): [True: 4.45k, False: 2.51k]
  ------------------
 5914|  4.45k|      mz_uint total_header_size, disk_index, bit_flags, filename_size,
 5915|  4.45k|          ext_data_size;
 5916|  4.45k|      mz_uint64 comp_size, decomp_size, local_header_ofs;
 5917|       |
 5918|  4.45k|      if ((n < MZ_ZIP_CENTRAL_DIR_HEADER_SIZE) ||
  ------------------
  |  Branch (5918:11): [True: 7, False: 4.44k]
  ------------------
 5919|  4.44k|          (MZ_READ_LE32(p) != MZ_ZIP_CENTRAL_DIR_HEADER_SIG))
  ------------------
  |  |  772|  4.44k|  ((mz_uint32)(((const mz_uint8 *)(p))[0]) |                                   \
  |  |  773|  4.44k|   ((mz_uint32)(((const mz_uint8 *)(p))[1]) << 8U) |                           \
  |  |  774|  4.44k|   ((mz_uint32)(((const mz_uint8 *)(p))[2]) << 16U) |                          \
  |  |  775|  4.44k|   ((mz_uint32)(((const mz_uint8 *)(p))[3]) << 24U))
  ------------------
  |  Branch (5919:11): [True: 56, False: 4.39k]
  ------------------
 5920|     63|        return mz_zip_set_error(pZip, MZ_ZIP_INVALID_HEADER_OR_CORRUPTED);
 5921|       |
 5922|  4.39k|      MZ_ZIP_ARRAY_ELEMENT(&pZip->m_pState->m_central_dir_offsets, mz_uint32,
  ------------------
  |  | 5355|  4.39k|  ((element_type *)((array_ptr)->m_p))[index]
  ------------------
 5923|  4.39k|                           i) =
 5924|  4.39k|          (mz_uint32)(p - (const mz_uint8 *)pZip->m_pState->m_central_dir.m_p);
 5925|       |
 5926|  4.39k|      if (sort_central_dir)
  ------------------
  |  Branch (5926:11): [True: 4.39k, False: 0]
  ------------------
 5927|  4.39k|        MZ_ZIP_ARRAY_ELEMENT(&pZip->m_pState->m_sorted_central_dir_offsets,
  ------------------
  |  | 5355|  4.39k|  ((element_type *)((array_ptr)->m_p))[index]
  ------------------
 5928|  4.39k|                             mz_uint32, i) = i;
 5929|       |
 5930|  4.39k|      comp_size = MZ_READ_LE32(p + MZ_ZIP_CDH_COMPRESSED_SIZE_OFS);
  ------------------
  |  |  772|  4.39k|  ((mz_uint32)(((const mz_uint8 *)(p))[0]) |                                   \
  |  |  773|  4.39k|   ((mz_uint32)(((const mz_uint8 *)(p))[1]) << 8U) |                           \
  |  |  774|  4.39k|   ((mz_uint32)(((const mz_uint8 *)(p))[2]) << 16U) |                          \
  |  |  775|  4.39k|   ((mz_uint32)(((const mz_uint8 *)(p))[3]) << 24U))
  ------------------
 5931|  4.39k|      decomp_size = MZ_READ_LE32(p + MZ_ZIP_CDH_DECOMPRESSED_SIZE_OFS);
  ------------------
  |  |  772|  4.39k|  ((mz_uint32)(((const mz_uint8 *)(p))[0]) |                                   \
  |  |  773|  4.39k|   ((mz_uint32)(((const mz_uint8 *)(p))[1]) << 8U) |                           \
  |  |  774|  4.39k|   ((mz_uint32)(((const mz_uint8 *)(p))[2]) << 16U) |                          \
  |  |  775|  4.39k|   ((mz_uint32)(((const mz_uint8 *)(p))[3]) << 24U))
  ------------------
 5932|  4.39k|      local_header_ofs = MZ_READ_LE32(p + MZ_ZIP_CDH_LOCAL_HEADER_OFS);
  ------------------
  |  |  772|  4.39k|  ((mz_uint32)(((const mz_uint8 *)(p))[0]) |                                   \
  |  |  773|  4.39k|   ((mz_uint32)(((const mz_uint8 *)(p))[1]) << 8U) |                           \
  |  |  774|  4.39k|   ((mz_uint32)(((const mz_uint8 *)(p))[2]) << 16U) |                          \
  |  |  775|  4.39k|   ((mz_uint32)(((const mz_uint8 *)(p))[3]) << 24U))
  ------------------
 5933|  4.39k|      filename_size = MZ_READ_LE16(p + MZ_ZIP_CDH_FILENAME_LEN_OFS);
  ------------------
  |  |  769|  4.39k|  ((mz_uint32)(((const mz_uint8 *)(p))[0]) |                                   \
  |  |  770|  4.39k|   ((mz_uint32)(((const mz_uint8 *)(p))[1]) << 8U))
  ------------------
 5934|  4.39k|      ext_data_size = MZ_READ_LE16(p + MZ_ZIP_CDH_EXTRA_LEN_OFS);
  ------------------
  |  |  769|  4.39k|  ((mz_uint32)(((const mz_uint8 *)(p))[0]) |                                   \
  |  |  770|  4.39k|   ((mz_uint32)(((const mz_uint8 *)(p))[1]) << 8U))
  ------------------
 5935|       |
 5936|  4.39k|      if ((!pZip->m_pState->m_zip64_has_extended_info_fields) &&
  ------------------
  |  Branch (5936:11): [True: 4.08k, False: 311]
  ------------------
 5937|  4.08k|          (ext_data_size) &&
  ------------------
  |  Branch (5937:11): [True: 2.27k, False: 1.80k]
  ------------------
 5938|  2.27k|          (MZ_MAX(MZ_MAX(comp_size, decomp_size), local_header_ofs) ==
  ------------------
  |  |  758|  4.55k|#define MZ_MAX(a, b) (((a) > (b)) ? (a) : (b))
  |  |  ------------------
  |  |  |  Branch (758:23): [True: 1.94k, False: 333]
  |  |  |  Branch (758:25): [True: 1.47k, False: 803]
  |  |  |  Branch (758:38): [True: 1.24k, False: 698]
  |  |  ------------------
  ------------------
  |  Branch (5938:11): [True: 1.33k, False: 940]
  ------------------
 5939|  2.27k|           MZ_UINT32_MAX)) {
  ------------------
  |  |  794|  2.27k|#define MZ_UINT32_MAX (0xFFFFFFFFU)
  ------------------
 5940|       |        /* Attempt to find zip64 extended information field in the entry's extra
 5941|       |         * data */
 5942|  1.33k|        mz_uint32 extra_size_remaining = ext_data_size;
 5943|       |
 5944|  1.33k|        if (extra_size_remaining) {
  ------------------
  |  Branch (5944:13): [True: 1.33k, False: 0]
  ------------------
 5945|  1.33k|          const mz_uint8 *pExtra_data;
 5946|  1.33k|          void *buf = NULL;
 5947|       |
 5948|  1.33k|          if (MZ_ZIP_CENTRAL_DIR_HEADER_SIZE + filename_size + ext_data_size >
  ------------------
  |  Branch (5948:15): [True: 92, False: 1.24k]
  ------------------
 5949|  1.33k|              n) {
 5950|     92|            buf = MZ_MALLOC(ext_data_size);
  ------------------
  |  |  753|     92|#define MZ_MALLOC(x) malloc(x)
  ------------------
 5951|     92|            if (buf == NULL)
  ------------------
  |  Branch (5951:17): [True: 0, False: 92]
  ------------------
 5952|      0|              return mz_zip_set_error(pZip, MZ_ZIP_ALLOC_FAILED);
 5953|       |
 5954|     92|            if (pZip->m_pRead(pZip->m_pIO_opaque,
  ------------------
  |  Branch (5954:17): [True: 42, False: 50]
  ------------------
 5955|     92|                              cdir_ofs + MZ_ZIP_CENTRAL_DIR_HEADER_SIZE +
 5956|     92|                                  filename_size,
 5957|     92|                              buf, ext_data_size) != ext_data_size) {
 5958|     42|              MZ_FREE(buf);
  ------------------
  |  |  754|     42|#define MZ_FREE(x) free(x)
  ------------------
 5959|     42|              return mz_zip_set_error(pZip, MZ_ZIP_FILE_READ_FAILED);
 5960|     42|            }
 5961|       |
 5962|     50|            pExtra_data = (mz_uint8 *)buf;
 5963|  1.24k|          } else {
 5964|  1.24k|            pExtra_data = p + MZ_ZIP_CENTRAL_DIR_HEADER_SIZE + filename_size;
 5965|  1.24k|          }
 5966|       |
 5967|  3.03k|          do {
 5968|  3.03k|            mz_uint32 field_id;
 5969|  3.03k|            mz_uint32 field_data_size;
 5970|       |
 5971|  3.03k|            if (extra_size_remaining < (sizeof(mz_uint16) * 2)) {
  ------------------
  |  Branch (5971:17): [True: 9, False: 3.02k]
  ------------------
 5972|      9|              MZ_FREE(buf);
  ------------------
  |  |  754|      9|#define MZ_FREE(x) free(x)
  ------------------
 5973|      9|              return mz_zip_set_error(pZip, MZ_ZIP_INVALID_HEADER_OR_CORRUPTED);
 5974|      9|            }
 5975|       |
 5976|  3.02k|            field_id = MZ_READ_LE16(pExtra_data);
  ------------------
  |  |  769|  3.02k|  ((mz_uint32)(((const mz_uint8 *)(p))[0]) |                                   \
  |  |  770|  3.02k|   ((mz_uint32)(((const mz_uint8 *)(p))[1]) << 8U))
  ------------------
 5977|  3.02k|            field_data_size = MZ_READ_LE16(pExtra_data + sizeof(mz_uint16));
  ------------------
  |  |  769|  3.02k|  ((mz_uint32)(((const mz_uint8 *)(p))[0]) |                                   \
  |  |  770|  3.02k|   ((mz_uint32)(((const mz_uint8 *)(p))[1]) << 8U))
  ------------------
 5978|       |
 5979|  3.02k|            if ((field_data_size + sizeof(mz_uint16) * 2) >
  ------------------
  |  Branch (5979:17): [True: 51, False: 2.97k]
  ------------------
 5980|  3.02k|                extra_size_remaining) {
 5981|     51|              MZ_FREE(buf);
  ------------------
  |  |  754|     51|#define MZ_FREE(x) free(x)
  ------------------
 5982|     51|              return mz_zip_set_error(pZip, MZ_ZIP_INVALID_HEADER_OR_CORRUPTED);
 5983|     51|            }
 5984|       |
 5985|  2.97k|            if (field_id == MZ_ZIP64_EXTENDED_INFORMATION_FIELD_HEADER_ID) {
  ------------------
  |  Branch (5985:17): [True: 631, False: 2.34k]
  ------------------
 5986|       |              /* Ok, the archive didn't have any zip64 headers but it uses a
 5987|       |               * zip64 extended information field so mark it as zip64 anyway
 5988|       |               * (this can occur with infozip's zip util when it reads
 5989|       |               * compresses files from stdin). */
 5990|    631|              pZip->m_pState->m_zip64 = MZ_TRUE;
  ------------------
  |  |  719|    631|#define MZ_TRUE (1)
  ------------------
 5991|    631|              pZip->m_pState->m_zip64_has_extended_info_fields = MZ_TRUE;
  ------------------
  |  |  719|    631|#define MZ_TRUE (1)
  ------------------
 5992|    631|              break;
 5993|    631|            }
 5994|       |
 5995|  2.34k|            pExtra_data += sizeof(mz_uint16) * 2 + field_data_size;
 5996|  2.34k|            extra_size_remaining =
 5997|  2.34k|                extra_size_remaining - sizeof(mz_uint16) * 2 - field_data_size;
 5998|  2.34k|          } while (extra_size_remaining);
  ------------------
  |  Branch (5998:20): [True: 1.74k, False: 602]
  ------------------
 5999|       |
 6000|  1.23k|          MZ_FREE(buf);
  ------------------
  |  |  754|  1.23k|#define MZ_FREE(x) free(x)
  ------------------
 6001|  1.23k|        }
 6002|  1.33k|      }
 6003|       |
 6004|       |      /* I've seen archives that aren't marked as zip64 that uses zip64 ext
 6005|       |       * data, argh */
 6006|  4.28k|      if ((comp_size != MZ_UINT32_MAX) && (decomp_size != MZ_UINT32_MAX)) {
  ------------------
  |  |  794|  4.28k|#define MZ_UINT32_MAX (0xFFFFFFFFU)
  ------------------
                    if ((comp_size != MZ_UINT32_MAX) && (decomp_size != MZ_UINT32_MAX)) {
  ------------------
  |  |  794|  2.00k|#define MZ_UINT32_MAX (0xFFFFFFFFU)
  ------------------
  |  Branch (6006:11): [True: 2.00k, False: 2.28k]
  |  Branch (6006:43): [True: 1.97k, False: 27]
  ------------------
 6007|  1.97k|        if (((!MZ_READ_LE32(p + MZ_ZIP_CDH_METHOD_OFS)) &&
  ------------------
  |  |  772|  1.97k|  ((mz_uint32)(((const mz_uint8 *)(p))[0]) |                                   \
  |  |  773|  1.97k|   ((mz_uint32)(((const mz_uint8 *)(p))[1]) << 8U) |                           \
  |  |  774|  1.97k|   ((mz_uint32)(((const mz_uint8 *)(p))[2]) << 16U) |                          \
  |  |  775|  1.97k|   ((mz_uint32)(((const mz_uint8 *)(p))[3]) << 24U))
  ------------------
  |  Branch (6007:14): [True: 125, False: 1.85k]
  ------------------
 6008|    125|             (decomp_size != comp_size)) ||
  ------------------
  |  Branch (6008:14): [True: 67, False: 58]
  ------------------
 6009|  1.90k|            (decomp_size && !comp_size))
  ------------------
  |  Branch (6009:14): [True: 1.62k, False: 288]
  |  Branch (6009:29): [True: 6, False: 1.61k]
  ------------------
 6010|     73|          return mz_zip_set_error(pZip, MZ_ZIP_INVALID_HEADER_OR_CORRUPTED);
 6011|  1.97k|      }
 6012|       |
 6013|  4.21k|      disk_index = MZ_READ_LE16(p + MZ_ZIP_CDH_DISK_START_OFS);
  ------------------
  |  |  769|  4.21k|  ((mz_uint32)(((const mz_uint8 *)(p))[0]) |                                   \
  |  |  770|  4.21k|   ((mz_uint32)(((const mz_uint8 *)(p))[1]) << 8U))
  ------------------
 6014|  4.21k|      if ((disk_index == MZ_UINT16_MAX) ||
  ------------------
  |  |  793|  4.21k|#define MZ_UINT16_MAX (0xFFFFU)
  ------------------
  |  Branch (6014:11): [True: 1, False: 4.21k]
  ------------------
 6015|  4.21k|          ((disk_index != num_this_disk) && (disk_index != 1)))
  ------------------
  |  Branch (6015:12): [True: 322, False: 3.89k]
  |  Branch (6015:45): [True: 77, False: 245]
  ------------------
 6016|     78|        return mz_zip_set_error(pZip, MZ_ZIP_UNSUPPORTED_MULTIDISK);
 6017|       |
 6018|  4.13k|      if (comp_size != MZ_UINT32_MAX) {
  ------------------
  |  |  794|  4.13k|#define MZ_UINT32_MAX (0xFFFFFFFFU)
  ------------------
  |  Branch (6018:11): [True: 1.85k, False: 2.28k]
  ------------------
 6019|  1.85k|        if (((mz_uint64)MZ_READ_LE32(p + MZ_ZIP_CDH_LOCAL_HEADER_OFS) +
  ------------------
  |  |  772|  1.85k|  ((mz_uint32)(((const mz_uint8 *)(p))[0]) |                                   \
  |  |  773|  1.85k|   ((mz_uint32)(((const mz_uint8 *)(p))[1]) << 8U) |                           \
  |  |  774|  1.85k|   ((mz_uint32)(((const mz_uint8 *)(p))[2]) << 16U) |                          \
  |  |  775|  1.85k|   ((mz_uint32)(((const mz_uint8 *)(p))[3]) << 24U))
  ------------------
  |  Branch (6019:13): [True: 82, False: 1.77k]
  ------------------
 6020|  1.85k|             MZ_ZIP_LOCAL_DIR_HEADER_SIZE + comp_size) > pZip->m_archive_size)
 6021|     82|          return mz_zip_set_error(pZip, MZ_ZIP_INVALID_HEADER_OR_CORRUPTED);
 6022|  1.85k|      }
 6023|       |
 6024|  4.05k|      bit_flags = MZ_READ_LE16(p + MZ_ZIP_CDH_BIT_FLAG_OFS);
  ------------------
  |  |  769|  4.05k|  ((mz_uint32)(((const mz_uint8 *)(p))[0]) |                                   \
  |  |  770|  4.05k|   ((mz_uint32)(((const mz_uint8 *)(p))[1]) << 8U))
  ------------------
 6025|  4.05k|      if (bit_flags & MZ_ZIP_GENERAL_PURPOSE_BIT_FLAG_LOCAL_DIR_IS_MASKED)
  ------------------
  |  Branch (6025:11): [True: 4, False: 4.05k]
  ------------------
 6026|      4|        return mz_zip_set_error(pZip, MZ_ZIP_UNSUPPORTED_ENCRYPTION);
 6027|       |
 6028|  4.05k|      if ((total_header_size = MZ_ZIP_CENTRAL_DIR_HEADER_SIZE +
  ------------------
  |  Branch (6028:11): [True: 34, False: 4.01k]
  ------------------
 6029|  4.05k|                               MZ_READ_LE16(p + MZ_ZIP_CDH_FILENAME_LEN_OFS) +
  ------------------
  |  |  769|  4.05k|  ((mz_uint32)(((const mz_uint8 *)(p))[0]) |                                   \
  |  |  770|  4.05k|   ((mz_uint32)(((const mz_uint8 *)(p))[1]) << 8U))
  ------------------
 6030|  4.05k|                               MZ_READ_LE16(p + MZ_ZIP_CDH_EXTRA_LEN_OFS) +
  ------------------
  |  |  769|  4.05k|  ((mz_uint32)(((const mz_uint8 *)(p))[0]) |                                   \
  |  |  770|  4.05k|   ((mz_uint32)(((const mz_uint8 *)(p))[1]) << 8U))
  ------------------
 6031|  4.05k|                               MZ_READ_LE16(p + MZ_ZIP_CDH_COMMENT_LEN_OFS)) >
  ------------------
  |  |  769|  4.05k|  ((mz_uint32)(((const mz_uint8 *)(p))[0]) |                                   \
  |  |  770|  4.05k|   ((mz_uint32)(((const mz_uint8 *)(p))[1]) << 8U))
  ------------------
 6032|  4.05k|          n)
 6033|     34|        return mz_zip_set_error(pZip, MZ_ZIP_INVALID_HEADER_OR_CORRUPTED);
 6034|       |
 6035|  4.01k|      n -= total_header_size;
 6036|  4.01k|      p += total_header_size;
 6037|  4.01k|    }
 6038|  2.94k|  }
 6039|       |
 6040|  2.55k|  if (sort_central_dir)
  ------------------
  |  Branch (6040:7): [True: 2.55k, False: 0]
  ------------------
 6041|  2.55k|    mz_zip_reader_sort_central_dir_offsets_by_filename(pZip);
 6042|       |
 6043|  2.55k|  return MZ_TRUE;
  ------------------
  |  |  719|  2.55k|#define MZ_TRUE (1)
  ------------------
 6044|  3.01k|}
zip.c:mz_zip_reader_locate_header_sig:
 5645|  3.82k|                                               mz_int64 *pOfs) {
 5646|  3.82k|  mz_int64 cur_file_ofs;
 5647|  3.82k|  mz_uint32 buf_u32[4096 / sizeof(mz_uint32)];
 5648|  3.82k|  mz_uint8 *pBuf = (mz_uint8 *)buf_u32;
 5649|       |
 5650|       |  /* Basic sanity checks - reject files which are too small */
 5651|  3.82k|  if (pZip->m_archive_size < record_size)
  ------------------
  |  Branch (5651:7): [True: 0, False: 3.82k]
  ------------------
 5652|      0|    return MZ_FALSE;
  ------------------
  |  |  718|      0|#define MZ_FALSE (0)
  ------------------
 5653|       |
 5654|       |  /* Find the record by scanning the file from the end towards the beginning. */
 5655|  3.82k|  cur_file_ofs =
 5656|  3.82k|      MZ_MAX((mz_int64)pZip->m_archive_size - (mz_int64)sizeof(buf_u32), 0);
  ------------------
  |  |  758|  3.82k|#define MZ_MAX(a, b) (((a) > (b)) ? (a) : (b))
  |  |  ------------------
  |  |  |  Branch (758:23): [True: 276, False: 3.54k]
  |  |  ------------------
  ------------------
 5657|  4.05k|  for (;;) {
 5658|  4.05k|    int i,
 5659|  4.05k|        n = (int)MZ_MIN(sizeof(buf_u32), pZip->m_archive_size - cur_file_ofs);
  ------------------
  |  |  759|  4.05k|#define MZ_MIN(a, b) (((a) < (b)) ? (a) : (b))
  |  |  ------------------
  |  |  |  Branch (759:23): [True: 228, False: 3.82k]
  |  |  ------------------
  ------------------
 5660|       |
 5661|  4.05k|    if (pZip->m_pRead(pZip->m_pIO_opaque, cur_file_ofs, pBuf, n) != (mz_uint)n)
  ------------------
  |  Branch (5661:9): [True: 8, False: 4.04k]
  ------------------
 5662|      8|      return MZ_FALSE;
  ------------------
  |  |  718|      8|#define MZ_FALSE (0)
  ------------------
 5663|       |
 5664|  1.16M|    for (i = n - 4; i >= 0; --i) {
  ------------------
  |  Branch (5664:21): [True: 1.16M, False: 279]
  ------------------
 5665|  1.16M|      mz_uint s = MZ_READ_LE32(pBuf + i);
  ------------------
  |  |  772|  1.16M|  ((mz_uint32)(((const mz_uint8 *)(p))[0]) |                                   \
  |  |  773|  1.16M|   ((mz_uint32)(((const mz_uint8 *)(p))[1]) << 8U) |                           \
  |  |  774|  1.16M|   ((mz_uint32)(((const mz_uint8 *)(p))[2]) << 16U) |                          \
  |  |  775|  1.16M|   ((mz_uint32)(((const mz_uint8 *)(p))[3]) << 24U))
  ------------------
 5666|  1.16M|      if (s == record_sig) {
  ------------------
  |  Branch (5666:11): [True: 3.80k, False: 1.15M]
  ------------------
 5667|  3.80k|        if ((pZip->m_archive_size - (cur_file_ofs + i)) >= record_size)
  ------------------
  |  Branch (5667:13): [True: 3.76k, False: 45]
  ------------------
 5668|  3.76k|          break;
 5669|  3.80k|      }
 5670|  1.16M|    }
 5671|       |
 5672|  4.04k|    if (i >= 0) {
  ------------------
  |  Branch (5672:9): [True: 3.76k, False: 279]
  ------------------
 5673|  3.76k|      cur_file_ofs += i;
 5674|  3.76k|      break;
 5675|  3.76k|    }
 5676|       |
 5677|       |    /* Give up if we've searched the entire file, or we've gone back "too far"
 5678|       |     * (~64kb) */
 5679|    279|    if ((!cur_file_ofs) || ((pZip->m_archive_size - cur_file_ofs) >=
  ------------------
  |  Branch (5679:9): [True: 46, False: 233]
  |  Branch (5679:28): [True: 5, False: 228]
  ------------------
 5680|    233|                            ((mz_uint64)(MZ_UINT16_MAX) + record_size)))
  ------------------
  |  |  793|    233|#define MZ_UINT16_MAX (0xFFFFU)
  ------------------
 5681|     51|      return MZ_FALSE;
  ------------------
  |  |  718|     51|#define MZ_FALSE (0)
  ------------------
 5682|       |
 5683|    228|    cur_file_ofs = MZ_MAX(cur_file_ofs - (sizeof(buf_u32) - 3), 0);
  ------------------
  |  |  758|    228|#define MZ_MAX(a, b) (((a) > (b)) ? (a) : (b))
  |  |  ------------------
  |  |  |  Branch (758:23): [True: 223, False: 5]
  |  |  ------------------
  ------------------
 5684|    228|  }
 5685|       |
 5686|  3.76k|  *pOfs = cur_file_ofs;
 5687|  3.76k|  return MZ_TRUE;
  ------------------
  |  |  719|  3.76k|#define MZ_TRUE (1)
  ------------------
 5688|  3.82k|}
zip.c:mz_zip_reader_eocd64_valid:
 5691|    877|                                          uint8_t *buf) {
 5692|    877|  if (pZip->m_pRead(pZip->m_pIO_opaque, offset, buf,
  ------------------
  |  Branch (5692:7): [True: 877, False: 0]
  ------------------
 5693|    877|                    MZ_ZIP64_END_OF_CENTRAL_DIR_HEADER_SIZE) ==
 5694|    877|      MZ_ZIP64_END_OF_CENTRAL_DIR_HEADER_SIZE) {
 5695|    877|    if (MZ_READ_LE32(buf + MZ_ZIP64_ECDH_SIG_OFS) ==
  ------------------
  |  |  772|    877|  ((mz_uint32)(((const mz_uint8 *)(p))[0]) |                                   \
  |  |  773|    877|   ((mz_uint32)(((const mz_uint8 *)(p))[1]) << 8U) |                           \
  |  |  774|    877|   ((mz_uint32)(((const mz_uint8 *)(p))[2]) << 16U) |                          \
  |  |  775|    877|   ((mz_uint32)(((const mz_uint8 *)(p))[3]) << 24U))
  ------------------
  |  Branch (5695:9): [True: 450, False: 427]
  ------------------
 5696|    877|        MZ_ZIP64_END_OF_CENTRAL_DIR_HEADER_SIG) {
 5697|    450|      return MZ_TRUE;
  ------------------
  |  |  719|    450|#define MZ_TRUE (1)
  ------------------
 5698|    450|    }
 5699|    877|  }
 5700|       |
 5701|    427|  return MZ_FALSE;
  ------------------
  |  |  718|    427|#define MZ_FALSE (0)
  ------------------
 5702|    877|}
zip.c:mz_zip_reader_sort_central_dir_offsets_by_filename:
 5586|  2.55k|mz_zip_reader_sort_central_dir_offsets_by_filename(mz_zip_archive *pZip) {
 5587|  2.55k|  mz_zip_internal_state *pState = pZip->m_pState;
 5588|  2.55k|  const mz_zip_array *pCentral_dir_offsets = &pState->m_central_dir_offsets;
 5589|  2.55k|  const mz_zip_array *pCentral_dir = &pState->m_central_dir;
 5590|  2.55k|  mz_uint32 *pIndices;
 5591|  2.55k|  mz_uint32 start, end;
 5592|  2.55k|  const mz_uint32 size = pZip->m_total_files;
 5593|       |
 5594|  2.55k|  if (size <= 1U)
  ------------------
  |  Branch (5594:7): [True: 1.71k, False: 845]
  ------------------
 5595|  1.71k|    return;
 5596|       |
 5597|    845|  pIndices = &MZ_ZIP_ARRAY_ELEMENT(&pState->m_sorted_central_dir_offsets,
  ------------------
  |  | 5355|    845|  ((element_type *)((array_ptr)->m_p))[index]
  ------------------
 5598|    845|                                   mz_uint32, 0);
 5599|       |
 5600|    845|  start = (size - 2U) >> 1U;
 5601|    845|  for (;;) {
 5602|    845|    mz_uint64 child, root = start;
 5603|  1.24k|    for (;;) {
 5604|  1.24k|      if ((child = (root << 1U) + 1U) >= size)
  ------------------
  |  Branch (5604:11): [True: 399, False: 845]
  ------------------
 5605|    399|        break;
 5606|    845|      child += (((child + 1U) < size) &&
  ------------------
  |  Branch (5606:17): [True: 550, False: 295]
  ------------------
 5607|    550|                (mz_zip_reader_filename_less(pCentral_dir, pCentral_dir_offsets,
  ------------------
  |  Branch (5607:17): [True: 285, False: 265]
  ------------------
 5608|    550|                                             pIndices[child],
 5609|    550|                                             pIndices[child + 1U])));
 5610|    845|      if (!mz_zip_reader_filename_less(pCentral_dir, pCentral_dir_offsets,
  ------------------
  |  Branch (5610:11): [True: 446, False: 399]
  ------------------
 5611|    845|                                       pIndices[root], pIndices[child]))
 5612|    446|        break;
 5613|    399|      MZ_SWAP_UINT32(pIndices[root], pIndices[child]);
  ------------------
  |  | 5575|    399|  do {                                                                         \
  |  | 5576|    399|    mz_uint32 t = a;                                                           \
  |  | 5577|    399|    a = b;                                                                     \
  |  | 5578|    399|    b = t;                                                                     \
  |  | 5579|    399|  }                                                                            \
  |  | 5580|    845|  MZ_MACRO_END
  |  |  ------------------
  |  |  |  |  726|    845|#define MZ_MACRO_END while (0)
  |  |  |  |  ------------------
  |  |  |  |  |  Branch (726:29): [Folded, False: 399]
  |  |  |  |  ------------------
  |  |  ------------------
  ------------------
 5614|    399|      root = child;
 5615|    399|    }
 5616|    845|    if (!start)
  ------------------
  |  Branch (5616:9): [True: 845, False: 0]
  ------------------
 5617|    845|      break;
 5618|      0|    start--;
 5619|      0|  }
 5620|       |
 5621|    845|  end = size - 1;
 5622|  2.24k|  while (end > 0) {
  ------------------
  |  Branch (5622:10): [True: 1.39k, False: 845]
  ------------------
 5623|  1.39k|    mz_uint64 child, root = 0;
 5624|  1.39k|    MZ_SWAP_UINT32(pIndices[end], pIndices[0]);
  ------------------
  |  | 5575|  1.39k|  do {                                                                         \
  |  | 5576|  1.39k|    mz_uint32 t = a;                                                           \
  |  | 5577|  1.39k|    a = b;                                                                     \
  |  | 5578|  1.39k|    b = t;                                                                     \
  |  | 5579|  1.39k|  }                                                                            \
  |  | 5580|  1.39k|  MZ_MACRO_END
  |  |  ------------------
  |  |  |  |  726|  1.39k|#define MZ_MACRO_END while (0)
  |  |  |  |  ------------------
  |  |  |  |  |  Branch (726:29): [Folded, False: 1.39k]
  |  |  |  |  ------------------
  |  |  ------------------
  ------------------
 5625|  1.64k|    for (;;) {
 5626|  1.64k|      if ((child = (root << 1U) + 1U) >= end)
  ------------------
  |  Branch (5626:11): [True: 1.09k, False: 550]
  ------------------
 5627|  1.09k|        break;
 5628|    550|      child +=
 5629|    550|          (((child + 1U) < end) &&
  ------------------
  |  Branch (5629:12): [True: 0, False: 550]
  ------------------
 5630|      0|           mz_zip_reader_filename_less(pCentral_dir, pCentral_dir_offsets,
  ------------------
  |  Branch (5630:12): [True: 0, False: 0]
  ------------------
 5631|      0|                                       pIndices[child], pIndices[child + 1U]));
 5632|    550|      if (!mz_zip_reader_filename_less(pCentral_dir, pCentral_dir_offsets,
  ------------------
  |  Branch (5632:11): [True: 297, False: 253]
  ------------------
 5633|    550|                                       pIndices[root], pIndices[child]))
 5634|    297|        break;
 5635|    253|      MZ_SWAP_UINT32(pIndices[root], pIndices[child]);
  ------------------
  |  | 5575|    253|  do {                                                                         \
  |  | 5576|    253|    mz_uint32 t = a;                                                           \
  |  | 5577|    253|    a = b;                                                                     \
  |  | 5578|    253|    b = t;                                                                     \
  |  | 5579|    253|  }                                                                            \
  |  | 5580|    550|  MZ_MACRO_END
  |  |  ------------------
  |  |  |  |  726|    550|#define MZ_MACRO_END while (0)
  |  |  |  |  ------------------
  |  |  |  |  |  Branch (726:29): [Folded, False: 253]
  |  |  |  |  ------------------
  |  |  ------------------
  ------------------
 5636|    253|      root = child;
 5637|    253|    }
 5638|  1.39k|    end--;
 5639|  1.39k|  }
 5640|    845|}
zip.c:mz_zip_reader_filename_less:
 5550|  1.94k|                            mz_uint l_index, mz_uint r_index) {
 5551|  1.94k|  const mz_uint8 *pL = &MZ_ZIP_ARRAY_ELEMENT(
  ------------------
  |  | 5355|  1.94k|  ((element_type *)((array_ptr)->m_p))[index]
  ------------------
 5552|  1.94k|                     pCentral_dir_array, mz_uint8,
 5553|  1.94k|                     MZ_ZIP_ARRAY_ELEMENT(pCentral_dir_offsets, mz_uint32,
 5554|  1.94k|                                          l_index)),
 5555|  1.94k|                 *pE;
 5556|  1.94k|  const mz_uint8 *pR = &MZ_ZIP_ARRAY_ELEMENT(
  ------------------
  |  | 5355|  1.94k|  ((element_type *)((array_ptr)->m_p))[index]
  ------------------
 5557|  1.94k|      pCentral_dir_array, mz_uint8,
 5558|  1.94k|      MZ_ZIP_ARRAY_ELEMENT(pCentral_dir_offsets, mz_uint32, r_index));
 5559|  1.94k|  mz_uint l_len = MZ_READ_LE16(pL + MZ_ZIP_CDH_FILENAME_LEN_OFS),
  ------------------
  |  |  769|  1.94k|  ((mz_uint32)(((const mz_uint8 *)(p))[0]) |                                   \
  |  |  770|  1.94k|   ((mz_uint32)(((const mz_uint8 *)(p))[1]) << 8U))
  ------------------
 5560|  1.94k|          r_len = MZ_READ_LE16(pR + MZ_ZIP_CDH_FILENAME_LEN_OFS);
  ------------------
  |  |  769|  1.94k|  ((mz_uint32)(((const mz_uint8 *)(p))[0]) |                                   \
  |  |  770|  1.94k|   ((mz_uint32)(((const mz_uint8 *)(p))[1]) << 8U))
  ------------------
 5561|  1.94k|  mz_uint8 l = 0, r = 0;
 5562|  1.94k|  pL += MZ_ZIP_CENTRAL_DIR_HEADER_SIZE;
 5563|  1.94k|  pR += MZ_ZIP_CENTRAL_DIR_HEADER_SIZE;
 5564|  1.94k|  pE = pL + MZ_MIN(l_len, r_len);
  ------------------
  |  |  759|  1.94k|#define MZ_MIN(a, b) (((a) < (b)) ? (a) : (b))
  |  |  ------------------
  |  |  |  Branch (759:23): [True: 717, False: 1.22k]
  |  |  ------------------
  ------------------
 5565|  7.30k|  while (pL < pE) {
  ------------------
  |  Branch (5565:10): [True: 6.73k, False: 563]
  ------------------
 5566|  6.73k|    if ((l = MZ_TOLOWER(*pL)) != (r = MZ_TOLOWER(*pR)))
  ------------------
  |  | 5215|  6.73k|#define MZ_TOLOWER(c) ((((c) >= 'A') && ((c) <= 'Z')) ? ((c) - 'A' + 'a') : (c))
  |  |  ------------------
  |  |  |  Branch (5215:25): [True: 4.06k, False: 2.66k]
  |  |  |  Branch (5215:41): [True: 956, False: 3.11k]
  |  |  ------------------
  ------------------
                  if ((l = MZ_TOLOWER(*pL)) != (r = MZ_TOLOWER(*pR)))
  ------------------
  |  | 5215|  6.73k|#define MZ_TOLOWER(c) ((((c) >= 'A') && ((c) <= 'Z')) ? ((c) - 'A' + 'a') : (c))
  |  |  ------------------
  |  |  |  Branch (5215:25): [True: 4.23k, False: 2.50k]
  |  |  |  Branch (5215:41): [True: 1.23k, False: 3.00k]
  |  |  ------------------
  ------------------
  |  Branch (5566:9): [True: 1.38k, False: 5.35k]
  ------------------
 5567|  1.38k|      break;
 5568|  5.35k|    pL++;
 5569|  5.35k|    pR++;
 5570|  5.35k|  }
 5571|  1.94k|  return (pL == pE) ? (l_len < r_len) : (l < r);
  ------------------
  |  Branch (5571:10): [True: 563, False: 1.38k]
  ------------------
 5572|  1.94k|}
zip.c:mz_zip_mem_read_func:
 6117|  14.9k|                                   void *pBuf, size_t n) {
 6118|  14.9k|  mz_zip_archive *pZip = (mz_zip_archive *)pOpaque;
 6119|  14.9k|  size_t s = (file_ofs >= pZip->m_archive_size)
  ------------------
  |  Branch (6119:14): [True: 259, False: 14.6k]
  ------------------
 6120|  14.9k|                 ? 0
 6121|  14.9k|                 : (size_t)MZ_MIN(pZip->m_archive_size - file_ofs, n);
  ------------------
  |  |  759|  14.6k|#define MZ_MIN(a, b) (((a) < (b)) ? (a) : (b))
  |  |  ------------------
  |  |  |  Branch (759:23): [True: 24, False: 14.6k]
  |  |  ------------------
  ------------------
 6122|  14.9k|  memcpy(pBuf, (const mz_uint8 *)pZip->m_pState->m_pMem + file_ofs, s);
 6123|  14.9k|  return s;
 6124|  14.9k|}
zip.c:mz_zip_get_cdh:
 6275|  31.9k|                                                     mz_uint file_index) {
 6276|  31.9k|  if ((!pZip) || (!pZip->m_pState) || (file_index >= pZip->m_total_files))
  ------------------
  |  Branch (6276:7): [True: 0, False: 31.9k]
  |  Branch (6276:18): [True: 0, False: 31.9k]
  |  Branch (6276:39): [True: 0, False: 31.9k]
  ------------------
 6277|      0|    return NULL;
 6278|  31.9k|  return &MZ_ZIP_ARRAY_ELEMENT(
  ------------------
  |  | 5355|  31.9k|  ((element_type *)((array_ptr)->m_p))[index]
  ------------------
 6279|  31.9k|      &pZip->m_pState->m_central_dir, mz_uint8,
 6280|  31.9k|      MZ_ZIP_ARRAY_ELEMENT(&pZip->m_pState->m_central_dir_offsets, mz_uint32,
 6281|  31.9k|                           file_index));
 6282|  31.9k|}
zip.c:mz_zip_string_equal:
 6496|  2.96k|                                                  mz_uint flags) {
 6497|  2.96k|  mz_uint i;
 6498|  2.96k|  if (flags & MZ_ZIP_FLAG_CASE_SENSITIVE)
  ------------------
  |  Branch (6498:7): [True: 2.96k, False: 0]
  ------------------
 6499|  2.96k|    return 0 == memcmp(pA, pB, len);
 6500|      0|  for (i = 0; i < len; ++i)
  ------------------
  |  Branch (6500:15): [True: 0, False: 0]
  ------------------
 6501|      0|    if (MZ_TOLOWER(pA[i]) != MZ_TOLOWER(pB[i]))
  ------------------
  |  | 5215|      0|#define MZ_TOLOWER(c) ((((c) >= 'A') && ((c) <= 'Z')) ? ((c) - 'A' + 'a') : (c))
  |  |  ------------------
  |  |  |  Branch (5215:25): [True: 0, False: 0]
  |  |  |  Branch (5215:41): [True: 0, False: 0]
  |  |  ------------------
  ------------------
                  if (MZ_TOLOWER(pA[i]) != MZ_TOLOWER(pB[i]))
  ------------------
  |  | 5215|      0|#define MZ_TOLOWER(c) ((((c) >= 'A') && ((c) <= 'Z')) ? ((c) - 'A' + 'a') : (c))
  |  |  ------------------
  |  |  |  Branch (5215:25): [True: 0, False: 0]
  |  |  |  Branch (5215:41): [True: 0, False: 0]
  |  |  ------------------
  ------------------
  |  Branch (6501:9): [True: 0, False: 0]
  ------------------
 6502|      0|      return MZ_FALSE;
  ------------------
  |  |  718|      0|#define MZ_FALSE (0)
  ------------------
 6503|      0|  return MZ_TRUE;
  ------------------
  |  |  719|      0|#define MZ_TRUE (1)
  ------------------
 6504|      0|}
zip.c:mz_zip_reader_extract_to_mem_no_alloc1:
 6653|  1.57k|    const mz_zip_archive_file_stat *st) {
 6654|  1.57k|  int status = TINFL_STATUS_DONE;
 6655|  1.57k|  mz_uint64 needed_size, cur_file_ofs, comp_remaining,
 6656|  1.57k|      out_buf_ofs = 0, read_buf_size, read_buf_ofs = 0, read_buf_avail;
 6657|  1.57k|  mz_zip_archive_file_stat file_stat;
 6658|  1.57k|  void *pRead_buf;
 6659|  1.57k|  mz_uint32
 6660|  1.57k|      local_header_u32[(MZ_ZIP_LOCAL_DIR_HEADER_SIZE + sizeof(mz_uint32) - 1) /
 6661|  1.57k|                       sizeof(mz_uint32)];
 6662|  1.57k|  mz_uint8 *pLocal_header = (mz_uint8 *)local_header_u32;
 6663|  1.57k|  tinfl_decompressor inflator;
 6664|       |
 6665|  1.57k|  if ((!pZip) || (!pZip->m_pState) || ((buf_size) && (!pBuf)) ||
  ------------------
  |  Branch (6665:7): [True: 0, False: 1.57k]
  |  Branch (6665:18): [True: 0, False: 1.57k]
  |  Branch (6665:40): [True: 1.43k, False: 137]
  |  Branch (6665:54): [True: 0, False: 1.43k]
  ------------------
 6666|  1.57k|      ((user_read_buf_size) && (!pUser_read_buf)) || (!pZip->m_pRead))
  ------------------
  |  Branch (6666:8): [True: 0, False: 1.57k]
  |  Branch (6666:32): [True: 0, False: 0]
  |  Branch (6666:54): [True: 0, False: 1.57k]
  ------------------
 6667|      0|    return mz_zip_set_error(pZip, MZ_ZIP_INVALID_PARAMETER);
 6668|       |
 6669|  1.57k|  if (st) {
  ------------------
  |  Branch (6669:7): [True: 0, False: 1.57k]
  ------------------
 6670|      0|    file_stat = *st;
 6671|  1.57k|  } else if (!mz_zip_reader_file_stat(pZip, file_index, &file_stat))
  ------------------
  |  Branch (6671:14): [True: 0, False: 1.57k]
  ------------------
 6672|      0|    return MZ_FALSE;
  ------------------
  |  |  718|      0|#define MZ_FALSE (0)
  ------------------
 6673|       |
 6674|       |  /* A directory or zero length file */
 6675|  1.57k|  if ((file_stat.m_is_directory) || (!file_stat.m_comp_size))
  ------------------
  |  Branch (6675:7): [True: 322, False: 1.25k]
  |  Branch (6675:37): [True: 35, False: 1.21k]
  ------------------
 6676|    357|    return MZ_TRUE;
  ------------------
  |  |  719|    357|#define MZ_TRUE (1)
  ------------------
 6677|       |
 6678|       |  /* Encryption and patch files are not supported. */
 6679|  1.21k|  if (file_stat.m_bit_flag &
  ------------------
  |  Branch (6679:7): [True: 230, False: 985]
  ------------------
 6680|  1.21k|      (MZ_ZIP_GENERAL_PURPOSE_BIT_FLAG_IS_ENCRYPTED |
 6681|  1.21k|       MZ_ZIP_GENERAL_PURPOSE_BIT_FLAG_USES_STRONG_ENCRYPTION |
 6682|  1.21k|       MZ_ZIP_GENERAL_PURPOSE_BIT_FLAG_COMPRESSED_PATCH_FLAG))
 6683|    230|    return mz_zip_set_error(pZip, MZ_ZIP_UNSUPPORTED_ENCRYPTION);
 6684|       |
 6685|       |  /* This function only supports decompressing stored and deflate. */
 6686|    985|  if ((!(flags & MZ_ZIP_FLAG_COMPRESSED_DATA)) && (file_stat.m_method != 0) &&
  ------------------
  |  Branch (6686:7): [True: 985, False: 0]
  |  Branch (6686:51): [True: 596, False: 389]
  ------------------
 6687|    596|      (file_stat.m_method != MZ_DEFLATED))
  ------------------
  |  |  316|    596|#define MZ_DEFLATED 8
  ------------------
  |  Branch (6687:7): [True: 80, False: 516]
  ------------------
 6688|     80|    return mz_zip_set_error(pZip, MZ_ZIP_UNSUPPORTED_METHOD);
 6689|       |
 6690|       |  /* Ensure supplied output buffer is large enough. */
 6691|    905|  needed_size = (flags & MZ_ZIP_FLAG_COMPRESSED_DATA) ? file_stat.m_comp_size
  ------------------
  |  Branch (6691:17): [True: 0, False: 905]
  ------------------
 6692|    905|                                                      : file_stat.m_uncomp_size;
 6693|    905|  if (buf_size < needed_size)
  ------------------
  |  Branch (6693:7): [True: 0, False: 905]
  ------------------
 6694|      0|    return mz_zip_set_error(pZip, MZ_ZIP_BUF_TOO_SMALL);
 6695|       |
 6696|       |  /* Read and parse the local directory entry. */
 6697|    905|  cur_file_ofs = file_stat.m_local_header_ofs;
 6698|    905|  if (pZip->m_pRead(pZip->m_pIO_opaque, cur_file_ofs, pLocal_header,
  ------------------
  |  Branch (6698:7): [True: 206, False: 699]
  ------------------
 6699|    905|                    MZ_ZIP_LOCAL_DIR_HEADER_SIZE) !=
 6700|    905|      MZ_ZIP_LOCAL_DIR_HEADER_SIZE)
 6701|    206|    return mz_zip_set_error(pZip, MZ_ZIP_FILE_READ_FAILED);
 6702|       |
 6703|    699|  if (MZ_READ_LE32(pLocal_header) != MZ_ZIP_LOCAL_DIR_HEADER_SIG)
  ------------------
  |  |  772|    699|  ((mz_uint32)(((const mz_uint8 *)(p))[0]) |                                   \
  |  |  773|    699|   ((mz_uint32)(((const mz_uint8 *)(p))[1]) << 8U) |                           \
  |  |  774|    699|   ((mz_uint32)(((const mz_uint8 *)(p))[2]) << 16U) |                          \
  |  |  775|    699|   ((mz_uint32)(((const mz_uint8 *)(p))[3]) << 24U))
  ------------------
  |  Branch (6703:7): [True: 53, False: 646]
  ------------------
 6704|     53|    return mz_zip_set_error(pZip, MZ_ZIP_INVALID_HEADER_OR_CORRUPTED);
 6705|       |
 6706|    646|  cur_file_ofs += (mz_uint64)(MZ_ZIP_LOCAL_DIR_HEADER_SIZE) +
 6707|    646|                  MZ_READ_LE16(pLocal_header + MZ_ZIP_LDH_FILENAME_LEN_OFS) +
  ------------------
  |  |  769|    646|  ((mz_uint32)(((const mz_uint8 *)(p))[0]) |                                   \
  |  |  770|    646|   ((mz_uint32)(((const mz_uint8 *)(p))[1]) << 8U))
  ------------------
 6708|    646|                  MZ_READ_LE16(pLocal_header + MZ_ZIP_LDH_EXTRA_LEN_OFS);
  ------------------
  |  |  769|    646|  ((mz_uint32)(((const mz_uint8 *)(p))[0]) |                                   \
  |  |  770|    646|   ((mz_uint32)(((const mz_uint8 *)(p))[1]) << 8U))
  ------------------
 6709|    646|  if ((cur_file_ofs + file_stat.m_comp_size) > pZip->m_archive_size)
  ------------------
  |  Branch (6709:7): [True: 86, False: 560]
  ------------------
 6710|     86|    return mz_zip_set_error(pZip, MZ_ZIP_INVALID_HEADER_OR_CORRUPTED);
 6711|       |
 6712|    560|  if ((flags & MZ_ZIP_FLAG_COMPRESSED_DATA) || (!file_stat.m_method)) {
  ------------------
  |  Branch (6712:7): [True: 0, False: 560]
  |  Branch (6712:48): [True: 92, False: 468]
  ------------------
 6713|       |    /* The file is stored or the caller has requested the compressed data. */
 6714|     92|    if (pZip->m_pRead(pZip->m_pIO_opaque, cur_file_ofs, pBuf,
  ------------------
  |  Branch (6714:9): [True: 4, False: 88]
  ------------------
 6715|     92|                      (size_t)needed_size) != needed_size)
 6716|      4|      return mz_zip_set_error(pZip, MZ_ZIP_FILE_READ_FAILED);
 6717|       |
 6718|     88|#ifndef MINIZ_DISABLE_ZIP_READER_CRC32_CHECKS
 6719|     88|    if ((flags & MZ_ZIP_FLAG_COMPRESSED_DATA) == 0) {
  ------------------
  |  Branch (6719:9): [True: 88, False: 0]
  ------------------
 6720|     88|      if (mz_crc32(MZ_CRC32_INIT, (const mz_uint8 *)pBuf,
  ------------------
  |  |  300|     88|#define MZ_CRC32_INIT (0)
  ------------------
  |  Branch (6720:11): [True: 82, False: 6]
  ------------------
 6721|     88|                   (size_t)file_stat.m_uncomp_size) != file_stat.m_crc32)
 6722|     82|        return mz_zip_set_error(pZip, MZ_ZIP_CRC_CHECK_FAILED);
 6723|     88|    }
 6724|      6|#endif
 6725|       |
 6726|      6|    return MZ_TRUE;
  ------------------
  |  |  719|      6|#define MZ_TRUE (1)
  ------------------
 6727|     88|  }
 6728|       |
 6729|       |  /* Decompress the file either directly from memory or from a file input
 6730|       |   * buffer. */
 6731|    468|  tinfl_init(&inflator);
  ------------------
  |  | 1191|    468|  do {                                                                         \
  |  | 1192|    468|    (r)->m_state = 0;                                                          \
  |  | 1193|    468|  }                                                                            \
  |  | 1194|    560|  MZ_MACRO_END
  |  |  ------------------
  |  |  |  |  726|    560|#define MZ_MACRO_END while (0)
  |  |  |  |  ------------------
  |  |  |  |  |  Branch (726:29): [Folded, False: 468]
  |  |  |  |  ------------------
  |  |  ------------------
  ------------------
 6732|       |
 6733|    468|  if (pZip->m_pState->m_pMem) {
  ------------------
  |  Branch (6733:7): [True: 468, False: 0]
  ------------------
 6734|       |    /* Read directly from the archive in memory. */
 6735|    468|    pRead_buf = (mz_uint8 *)pZip->m_pState->m_pMem + cur_file_ofs;
 6736|    468|    read_buf_size = read_buf_avail = file_stat.m_comp_size;
 6737|    468|    comp_remaining = 0;
 6738|    468|  } else if (pUser_read_buf) {
  ------------------
  |  Branch (6738:14): [True: 0, False: 0]
  ------------------
 6739|       |    /* Use a user provided read buffer. */
 6740|      0|    if (!user_read_buf_size)
  ------------------
  |  Branch (6740:9): [True: 0, False: 0]
  ------------------
 6741|      0|      return MZ_FALSE;
  ------------------
  |  |  718|      0|#define MZ_FALSE (0)
  ------------------
 6742|      0|    pRead_buf = (mz_uint8 *)pUser_read_buf;
 6743|      0|    read_buf_size = user_read_buf_size;
 6744|      0|    read_buf_avail = 0;
 6745|      0|    comp_remaining = file_stat.m_comp_size;
 6746|      0|  } else {
 6747|       |    /* Temporarily allocate a read buffer. */
 6748|      0|    read_buf_size =
 6749|      0|        MZ_MIN(file_stat.m_comp_size, (mz_uint64)MZ_ZIP_MAX_IO_BUF_SIZE);
  ------------------
  |  |  759|      0|#define MZ_MIN(a, b) (((a) < (b)) ? (a) : (b))
  |  |  ------------------
  |  |  |  Branch (759:23): [True: 0, False: 0]
  |  |  ------------------
  ------------------
 6750|      0|    if (((sizeof(size_t) == sizeof(mz_uint32))) && (read_buf_size > 0x7FFFFFFF))
  ------------------
  |  Branch (6750:9): [Folded, False: 0]
  |  Branch (6750:52): [True: 0, False: 0]
  ------------------
 6751|      0|      return mz_zip_set_error(pZip, MZ_ZIP_INTERNAL_ERROR);
 6752|       |
 6753|      0|    if (NULL == (pRead_buf = pZip->m_pAlloc(pZip->m_pAlloc_opaque, 1,
  ------------------
  |  Branch (6753:9): [True: 0, False: 0]
  ------------------
 6754|      0|                                            (size_t)read_buf_size)))
 6755|      0|      return mz_zip_set_error(pZip, MZ_ZIP_ALLOC_FAILED);
 6756|       |
 6757|      0|    read_buf_avail = 0;
 6758|      0|    comp_remaining = file_stat.m_comp_size;
 6759|      0|  }
 6760|       |
 6761|    468|  do {
 6762|       |    /* The size_t cast here should be OK because we've verified that the output
 6763|       |     * buffer is >= file_stat.m_uncomp_size above */
 6764|    468|    size_t in_buf_size,
 6765|    468|        out_buf_size = (size_t)(file_stat.m_uncomp_size - out_buf_ofs);
 6766|    468|    if ((!read_buf_avail) && (!pZip->m_pState->m_pMem)) {
  ------------------
  |  Branch (6766:9): [True: 0, False: 468]
  |  Branch (6766:30): [True: 0, False: 0]
  ------------------
 6767|      0|      read_buf_avail = MZ_MIN(read_buf_size, comp_remaining);
  ------------------
  |  |  759|      0|#define MZ_MIN(a, b) (((a) < (b)) ? (a) : (b))
  |  |  ------------------
  |  |  |  Branch (759:23): [True: 0, False: 0]
  |  |  ------------------
  ------------------
 6768|      0|      if (pZip->m_pRead(pZip->m_pIO_opaque, cur_file_ofs, pRead_buf,
  ------------------
  |  Branch (6768:11): [True: 0, False: 0]
  ------------------
 6769|      0|                        (size_t)read_buf_avail) != read_buf_avail) {
 6770|      0|        status = TINFL_STATUS_FAILED;
 6771|      0|        mz_zip_set_error(pZip, MZ_ZIP_DECOMPRESSION_FAILED);
 6772|      0|        break;
 6773|      0|      }
 6774|      0|      cur_file_ofs += read_buf_avail;
 6775|      0|      comp_remaining -= read_buf_avail;
 6776|      0|      read_buf_ofs = 0;
 6777|      0|    }
 6778|    468|    in_buf_size = (size_t)read_buf_avail;
 6779|    468|    status = tinfl_decompress(
 6780|    468|        &inflator, (mz_uint8 *)pRead_buf + read_buf_ofs, &in_buf_size,
 6781|    468|        (mz_uint8 *)pBuf, (mz_uint8 *)pBuf + out_buf_ofs, &out_buf_size,
 6782|    468|        TINFL_FLAG_USING_NON_WRAPPING_OUTPUT_BUF |
 6783|    468|            (comp_remaining ? TINFL_FLAG_HAS_MORE_INPUT : 0));
  ------------------
  |  Branch (6783:14): [True: 0, False: 468]
  ------------------
 6784|    468|    read_buf_avail -= in_buf_size;
 6785|    468|    read_buf_ofs += in_buf_size;
 6786|    468|    out_buf_ofs += out_buf_size;
 6787|    468|  } while (status == TINFL_STATUS_NEEDS_MORE_INPUT);
  ------------------
  |  Branch (6787:12): [True: 0, False: 468]
  ------------------
 6788|       |
 6789|    468|  if (status == TINFL_STATUS_DONE) {
  ------------------
  |  Branch (6789:7): [True: 73, False: 395]
  ------------------
 6790|       |    /* Make sure the entire file was decompressed, and check its CRC. */
 6791|     73|    if (out_buf_ofs != file_stat.m_uncomp_size) {
  ------------------
  |  Branch (6791:9): [True: 12, False: 61]
  ------------------
 6792|     12|      mz_zip_set_error(pZip, MZ_ZIP_UNEXPECTED_DECOMPRESSED_SIZE);
 6793|     12|      status = TINFL_STATUS_FAILED;
 6794|     12|    }
 6795|     61|#ifndef MINIZ_DISABLE_ZIP_READER_CRC32_CHECKS
 6796|     61|    else if (mz_crc32(MZ_CRC32_INIT, (const mz_uint8 *)pBuf,
  ------------------
  |  |  300|     61|#define MZ_CRC32_INIT (0)
  ------------------
  |  Branch (6796:14): [True: 55, False: 6]
  ------------------
 6797|     61|                      (size_t)file_stat.m_uncomp_size) != file_stat.m_crc32) {
 6798|     55|      mz_zip_set_error(pZip, MZ_ZIP_CRC_CHECK_FAILED);
 6799|     55|      status = TINFL_STATUS_FAILED;
 6800|     55|    }
 6801|     73|#endif
 6802|     73|  }
 6803|       |
 6804|    468|  if ((!pZip->m_pState->m_pMem) && (!pUser_read_buf))
  ------------------
  |  Branch (6804:7): [True: 0, False: 468]
  |  Branch (6804:36): [True: 0, False: 0]
  ------------------
 6805|      0|    pZip->m_pFree(pZip->m_pAlloc_opaque, pRead_buf);
 6806|       |
 6807|    468|  return status == TINFL_STATUS_DONE;
 6808|    468|}
zip.c:mz_zip_file_stat_internal:
 6369|  7.99k|                                         mz_bool *pFound_zip64_extra_data) {
 6370|  7.99k|  mz_uint n;
 6371|  7.99k|  const mz_uint8 *p = pCentral_dir_header;
 6372|       |
 6373|  7.99k|  if (pFound_zip64_extra_data)
  ------------------
  |  Branch (6373:7): [True: 0, False: 7.99k]
  ------------------
 6374|      0|    *pFound_zip64_extra_data = MZ_FALSE;
  ------------------
  |  |  718|      0|#define MZ_FALSE (0)
  ------------------
 6375|       |
 6376|  7.99k|  if ((!p) || (!pStat))
  ------------------
  |  Branch (6376:7): [True: 0, False: 7.99k]
  |  Branch (6376:15): [True: 0, False: 7.99k]
  ------------------
 6377|      0|    return mz_zip_set_error(pZip, MZ_ZIP_INVALID_PARAMETER);
 6378|       |
 6379|       |  /* Extract fields from the central directory record. */
 6380|  7.99k|  pStat->m_file_index = file_index;
 6381|  7.99k|  pStat->m_central_dir_ofs = MZ_ZIP_ARRAY_ELEMENT(
  ------------------
  |  | 5355|  7.99k|  ((element_type *)((array_ptr)->m_p))[index]
  ------------------
 6382|  7.99k|      &pZip->m_pState->m_central_dir_offsets, mz_uint32, file_index);
 6383|  7.99k|  pStat->m_version_made_by = MZ_READ_LE16(p + MZ_ZIP_CDH_VERSION_MADE_BY_OFS);
  ------------------
  |  |  769|  7.99k|  ((mz_uint32)(((const mz_uint8 *)(p))[0]) |                                   \
  |  |  770|  7.99k|   ((mz_uint32)(((const mz_uint8 *)(p))[1]) << 8U))
  ------------------
 6384|  7.99k|  pStat->m_version_needed = MZ_READ_LE16(p + MZ_ZIP_CDH_VERSION_NEEDED_OFS);
  ------------------
  |  |  769|  7.99k|  ((mz_uint32)(((const mz_uint8 *)(p))[0]) |                                   \
  |  |  770|  7.99k|   ((mz_uint32)(((const mz_uint8 *)(p))[1]) << 8U))
  ------------------
 6385|  7.99k|  pStat->m_bit_flag = MZ_READ_LE16(p + MZ_ZIP_CDH_BIT_FLAG_OFS);
  ------------------
  |  |  769|  7.99k|  ((mz_uint32)(((const mz_uint8 *)(p))[0]) |                                   \
  |  |  770|  7.99k|   ((mz_uint32)(((const mz_uint8 *)(p))[1]) << 8U))
  ------------------
 6386|  7.99k|  pStat->m_method = MZ_READ_LE16(p + MZ_ZIP_CDH_METHOD_OFS);
  ------------------
  |  |  769|  7.99k|  ((mz_uint32)(((const mz_uint8 *)(p))[0]) |                                   \
  |  |  770|  7.99k|   ((mz_uint32)(((const mz_uint8 *)(p))[1]) << 8U))
  ------------------
 6387|  7.99k|#ifndef MINIZ_NO_TIME
 6388|  7.99k|  pStat->m_time =
 6389|  7.99k|      mz_zip_dos_to_time_t(MZ_READ_LE16(p + MZ_ZIP_CDH_FILE_TIME_OFS),
  ------------------
  |  |  769|  7.99k|  ((mz_uint32)(((const mz_uint8 *)(p))[0]) |                                   \
  |  |  770|  7.99k|   ((mz_uint32)(((const mz_uint8 *)(p))[1]) << 8U))
  ------------------
 6390|  7.99k|                           MZ_READ_LE16(p + MZ_ZIP_CDH_FILE_DATE_OFS));
  ------------------
  |  |  769|  7.99k|  ((mz_uint32)(((const mz_uint8 *)(p))[0]) |                                   \
  |  |  770|  7.99k|   ((mz_uint32)(((const mz_uint8 *)(p))[1]) << 8U))
  ------------------
 6391|  7.99k|#endif
 6392|  7.99k|  pStat->m_crc32 = MZ_READ_LE32(p + MZ_ZIP_CDH_CRC32_OFS);
  ------------------
  |  |  772|  7.99k|  ((mz_uint32)(((const mz_uint8 *)(p))[0]) |                                   \
  |  |  773|  7.99k|   ((mz_uint32)(((const mz_uint8 *)(p))[1]) << 8U) |                           \
  |  |  774|  7.99k|   ((mz_uint32)(((const mz_uint8 *)(p))[2]) << 16U) |                          \
  |  |  775|  7.99k|   ((mz_uint32)(((const mz_uint8 *)(p))[3]) << 24U))
  ------------------
 6393|  7.99k|  pStat->m_comp_size = MZ_READ_LE32(p + MZ_ZIP_CDH_COMPRESSED_SIZE_OFS);
  ------------------
  |  |  772|  7.99k|  ((mz_uint32)(((const mz_uint8 *)(p))[0]) |                                   \
  |  |  773|  7.99k|   ((mz_uint32)(((const mz_uint8 *)(p))[1]) << 8U) |                           \
  |  |  774|  7.99k|   ((mz_uint32)(((const mz_uint8 *)(p))[2]) << 16U) |                          \
  |  |  775|  7.99k|   ((mz_uint32)(((const mz_uint8 *)(p))[3]) << 24U))
  ------------------
 6394|  7.99k|  pStat->m_uncomp_size = MZ_READ_LE32(p + MZ_ZIP_CDH_DECOMPRESSED_SIZE_OFS);
  ------------------
  |  |  772|  7.99k|  ((mz_uint32)(((const mz_uint8 *)(p))[0]) |                                   \
  |  |  773|  7.99k|   ((mz_uint32)(((const mz_uint8 *)(p))[1]) << 8U) |                           \
  |  |  774|  7.99k|   ((mz_uint32)(((const mz_uint8 *)(p))[2]) << 16U) |                          \
  |  |  775|  7.99k|   ((mz_uint32)(((const mz_uint8 *)(p))[3]) << 24U))
  ------------------
 6395|  7.99k|  pStat->m_internal_attr = MZ_READ_LE16(p + MZ_ZIP_CDH_INTERNAL_ATTR_OFS);
  ------------------
  |  |  769|  7.99k|  ((mz_uint32)(((const mz_uint8 *)(p))[0]) |                                   \
  |  |  770|  7.99k|   ((mz_uint32)(((const mz_uint8 *)(p))[1]) << 8U))
  ------------------
 6396|  7.99k|  pStat->m_external_attr = MZ_READ_LE32(p + MZ_ZIP_CDH_EXTERNAL_ATTR_OFS);
  ------------------
  |  |  772|  7.99k|  ((mz_uint32)(((const mz_uint8 *)(p))[0]) |                                   \
  |  |  773|  7.99k|   ((mz_uint32)(((const mz_uint8 *)(p))[1]) << 8U) |                           \
  |  |  774|  7.99k|   ((mz_uint32)(((const mz_uint8 *)(p))[2]) << 16U) |                          \
  |  |  775|  7.99k|   ((mz_uint32)(((const mz_uint8 *)(p))[3]) << 24U))
  ------------------
 6397|  7.99k|  pStat->m_local_header_ofs = MZ_READ_LE32(p + MZ_ZIP_CDH_LOCAL_HEADER_OFS);
  ------------------
  |  |  772|  7.99k|  ((mz_uint32)(((const mz_uint8 *)(p))[0]) |                                   \
  |  |  773|  7.99k|   ((mz_uint32)(((const mz_uint8 *)(p))[1]) << 8U) |                           \
  |  |  774|  7.99k|   ((mz_uint32)(((const mz_uint8 *)(p))[2]) << 16U) |                          \
  |  |  775|  7.99k|   ((mz_uint32)(((const mz_uint8 *)(p))[3]) << 24U))
  ------------------
 6398|       |
 6399|       |  /* Copy as much of the filename and comment as possible. */
 6400|  7.99k|  n = MZ_READ_LE16(p + MZ_ZIP_CDH_FILENAME_LEN_OFS);
  ------------------
  |  |  769|  7.99k|  ((mz_uint32)(((const mz_uint8 *)(p))[0]) |                                   \
  |  |  770|  7.99k|   ((mz_uint32)(((const mz_uint8 *)(p))[1]) << 8U))
  ------------------
 6401|  7.99k|  n = MZ_MIN(n, MZ_ZIP_MAX_ARCHIVE_FILENAME_SIZE - 1);
  ------------------
  |  |  759|  7.99k|#define MZ_MIN(a, b) (((a) < (b)) ? (a) : (b))
  |  |  ------------------
  |  |  |  Branch (759:23): [True: 7.78k, False: 213]
  |  |  ------------------
  ------------------
 6402|  7.99k|  memcpy(pStat->m_filename, p + MZ_ZIP_CENTRAL_DIR_HEADER_SIZE, n);
 6403|  7.99k|  pStat->m_filename[n] = '\0';
 6404|       |
 6405|  7.99k|  n = MZ_READ_LE16(p + MZ_ZIP_CDH_COMMENT_LEN_OFS);
  ------------------
  |  |  769|  7.99k|  ((mz_uint32)(((const mz_uint8 *)(p))[0]) |                                   \
  |  |  770|  7.99k|   ((mz_uint32)(((const mz_uint8 *)(p))[1]) << 8U))
  ------------------
 6406|  7.99k|  n = MZ_MIN(n, MZ_ZIP_MAX_ARCHIVE_FILE_COMMENT_SIZE - 1);
  ------------------
  |  |  759|  7.99k|#define MZ_MIN(a, b) (((a) < (b)) ? (a) : (b))
  |  |  ------------------
  |  |  |  Branch (759:23): [True: 7.97k, False: 20]
  |  |  ------------------
  ------------------
 6407|  7.99k|  pStat->m_comment_size = n;
 6408|  7.99k|  memcpy(pStat->m_comment,
 6409|  7.99k|         p + MZ_ZIP_CENTRAL_DIR_HEADER_SIZE +
 6410|  7.99k|             MZ_READ_LE16(p + MZ_ZIP_CDH_FILENAME_LEN_OFS) +
  ------------------
  |  |  769|  7.99k|  ((mz_uint32)(((const mz_uint8 *)(p))[0]) |                                   \
  |  |  770|  7.99k|   ((mz_uint32)(((const mz_uint8 *)(p))[1]) << 8U))
  ------------------
 6411|  7.99k|             MZ_READ_LE16(p + MZ_ZIP_CDH_EXTRA_LEN_OFS),
  ------------------
  |  |  769|  7.99k|  ((mz_uint32)(((const mz_uint8 *)(p))[0]) |                                   \
  |  |  770|  7.99k|   ((mz_uint32)(((const mz_uint8 *)(p))[1]) << 8U))
  ------------------
 6412|  7.99k|         n);
 6413|  7.99k|  pStat->m_comment[n] = '\0';
 6414|       |
 6415|       |  /* Set some flags for convienance */
 6416|  7.99k|  pStat->m_is_directory = mz_zip_reader_is_file_a_directory(pZip, file_index);
 6417|  7.99k|  pStat->m_is_encrypted = mz_zip_reader_is_file_encrypted(pZip, file_index);
 6418|  7.99k|  pStat->m_is_supported = mz_zip_reader_is_file_supported(pZip, file_index);
 6419|       |
 6420|       |  /* See if we need to read any zip64 extended information fields. */
 6421|       |  /* Confusingly, these zip64 fields can be present even on non-zip64 archives
 6422|       |   * (Debian zip on a huge files from stdin piped to stdout creates them). */
 6423|  7.99k|  if (MZ_MAX(MZ_MAX(pStat->m_comp_size, pStat->m_uncomp_size),
  ------------------
  |  |  758|  15.9k|#define MZ_MAX(a, b) (((a) > (b)) ? (a) : (b))
  |  |  ------------------
  |  |  |  Branch (758:23): [True: 6.58k, False: 1.41k]
  |  |  |  Branch (758:25): [True: 4.66k, False: 3.33k]
  |  |  |  Branch (758:38): [True: 4.01k, False: 2.56k]
  |  |  ------------------
  ------------------
  |  Branch (6423:7): [True: 4.18k, False: 3.81k]
  ------------------
 6424|  7.99k|             pStat->m_local_header_ofs) == MZ_UINT32_MAX) {
  ------------------
  |  |  794|  7.99k|#define MZ_UINT32_MAX (0xFFFFFFFFU)
  ------------------
 6425|       |    /* Attempt to find zip64 extended information field in the entry's extra
 6426|       |     * data */
 6427|  4.18k|    mz_uint32 extra_size_remaining = MZ_READ_LE16(p + MZ_ZIP_CDH_EXTRA_LEN_OFS);
  ------------------
  |  |  769|  4.18k|  ((mz_uint32)(((const mz_uint8 *)(p))[0]) |                                   \
  |  |  770|  4.18k|   ((mz_uint32)(((const mz_uint8 *)(p))[1]) << 8U))
  ------------------
 6428|       |
 6429|  4.18k|    if (extra_size_remaining) {
  ------------------
  |  Branch (6429:9): [True: 2.37k, False: 1.80k]
  ------------------
 6430|  2.37k|      const mz_uint8 *pExtra_data =
 6431|  2.37k|          p + MZ_ZIP_CENTRAL_DIR_HEADER_SIZE +
 6432|  2.37k|          MZ_READ_LE16(p + MZ_ZIP_CDH_FILENAME_LEN_OFS);
  ------------------
  |  |  769|  2.37k|  ((mz_uint32)(((const mz_uint8 *)(p))[0]) |                                   \
  |  |  770|  2.37k|   ((mz_uint32)(((const mz_uint8 *)(p))[1]) << 8U))
  ------------------
 6433|       |
 6434|  4.09k|      do {
 6435|  4.09k|        mz_uint32 field_id;
 6436|  4.09k|        mz_uint32 field_data_size;
 6437|       |
 6438|  4.09k|        if (extra_size_remaining < (sizeof(mz_uint16) * 2))
  ------------------
  |  Branch (6438:13): [True: 31, False: 4.06k]
  ------------------
 6439|     31|          return mz_zip_set_error(pZip, MZ_ZIP_INVALID_HEADER_OR_CORRUPTED);
 6440|       |
 6441|  4.06k|        field_id = MZ_READ_LE16(pExtra_data);
  ------------------
  |  |  769|  4.06k|  ((mz_uint32)(((const mz_uint8 *)(p))[0]) |                                   \
  |  |  770|  4.06k|   ((mz_uint32)(((const mz_uint8 *)(p))[1]) << 8U))
  ------------------
 6442|  4.06k|        field_data_size = MZ_READ_LE16(pExtra_data + sizeof(mz_uint16));
  ------------------
  |  |  769|  4.06k|  ((mz_uint32)(((const mz_uint8 *)(p))[0]) |                                   \
  |  |  770|  4.06k|   ((mz_uint32)(((const mz_uint8 *)(p))[1]) << 8U))
  ------------------
 6443|       |
 6444|  4.06k|        if ((field_data_size + sizeof(mz_uint16) * 2) > extra_size_remaining)
  ------------------
  |  Branch (6444:13): [True: 78, False: 3.98k]
  ------------------
 6445|     78|          return mz_zip_set_error(pZip, MZ_ZIP_INVALID_HEADER_OR_CORRUPTED);
 6446|       |
 6447|  3.98k|        if (field_id == MZ_ZIP64_EXTENDED_INFORMATION_FIELD_HEADER_ID) {
  ------------------
  |  Branch (6447:13): [True: 1.34k, False: 2.64k]
  ------------------
 6448|  1.34k|          const mz_uint8 *pField_data = pExtra_data + sizeof(mz_uint16) * 2;
 6449|  1.34k|          mz_uint32 field_data_remaining = field_data_size;
 6450|       |
 6451|  1.34k|          if (pFound_zip64_extra_data)
  ------------------
  |  Branch (6451:15): [True: 0, False: 1.34k]
  ------------------
 6452|      0|            *pFound_zip64_extra_data = MZ_TRUE;
  ------------------
  |  |  719|      0|#define MZ_TRUE (1)
  ------------------
 6453|       |
 6454|  1.34k|          if (pStat->m_uncomp_size == MZ_UINT32_MAX) {
  ------------------
  |  |  794|  1.34k|#define MZ_UINT32_MAX (0xFFFFFFFFU)
  ------------------
  |  Branch (6454:15): [True: 76, False: 1.26k]
  ------------------
 6455|     76|            if (field_data_remaining < sizeof(mz_uint64))
  ------------------
  |  Branch (6455:17): [True: 15, False: 61]
  ------------------
 6456|     15|              return mz_zip_set_error(pZip, MZ_ZIP_INVALID_HEADER_OR_CORRUPTED);
 6457|       |
 6458|     61|            pStat->m_uncomp_size = MZ_READ_LE64(pField_data);
  ------------------
  |  |  779|     61|  (((mz_uint64)MZ_READ_LE32(p)) |                                              \
  |  |  ------------------
  |  |  |  |  772|     61|  ((mz_uint32)(((const mz_uint8 *)(p))[0]) |                                   \
  |  |  |  |  773|     61|   ((mz_uint32)(((const mz_uint8 *)(p))[1]) << 8U) |                           \
  |  |  |  |  774|     61|   ((mz_uint32)(((const mz_uint8 *)(p))[2]) << 16U) |                          \
  |  |  |  |  775|     61|   ((mz_uint32)(((const mz_uint8 *)(p))[3]) << 24U))
  |  |  ------------------
  |  |  780|     61|   (((mz_uint64)MZ_READ_LE32((const mz_uint8 *)(p) + sizeof(mz_uint32)))       \
  |  |  ------------------
  |  |  |  |  772|     61|  ((mz_uint32)(((const mz_uint8 *)(p))[0]) |                                   \
  |  |  |  |  773|     61|   ((mz_uint32)(((const mz_uint8 *)(p))[1]) << 8U) |                           \
  |  |  |  |  774|     61|   ((mz_uint32)(((const mz_uint8 *)(p))[2]) << 16U) |                          \
  |  |  |  |  775|     61|   ((mz_uint32)(((const mz_uint8 *)(p))[3]) << 24U))
  |  |  ------------------
  |  |  781|     61|    << 32U))
  ------------------
 6459|     61|            pField_data += sizeof(mz_uint64);
 6460|     61|            field_data_remaining -= sizeof(mz_uint64);
 6461|     61|          }
 6462|       |
 6463|  1.32k|          if (pStat->m_comp_size == MZ_UINT32_MAX) {
  ------------------
  |  |  794|  1.32k|#define MZ_UINT32_MAX (0xFFFFFFFFU)
  ------------------
  |  Branch (6463:15): [True: 1.29k, False: 31]
  ------------------
 6464|  1.29k|            if (field_data_remaining < sizeof(mz_uint64))
  ------------------
  |  Branch (6464:17): [True: 205, False: 1.09k]
  ------------------
 6465|    205|              return mz_zip_set_error(pZip, MZ_ZIP_INVALID_HEADER_OR_CORRUPTED);
 6466|       |
 6467|  1.09k|            pStat->m_comp_size = MZ_READ_LE64(pField_data);
  ------------------
  |  |  779|  1.09k|  (((mz_uint64)MZ_READ_LE32(p)) |                                              \
  |  |  ------------------
  |  |  |  |  772|  1.09k|  ((mz_uint32)(((const mz_uint8 *)(p))[0]) |                                   \
  |  |  |  |  773|  1.09k|   ((mz_uint32)(((const mz_uint8 *)(p))[1]) << 8U) |                           \
  |  |  |  |  774|  1.09k|   ((mz_uint32)(((const mz_uint8 *)(p))[2]) << 16U) |                          \
  |  |  |  |  775|  1.09k|   ((mz_uint32)(((const mz_uint8 *)(p))[3]) << 24U))
  |  |  ------------------
  |  |  780|  1.09k|   (((mz_uint64)MZ_READ_LE32((const mz_uint8 *)(p) + sizeof(mz_uint32)))       \
  |  |  ------------------
  |  |  |  |  772|  1.09k|  ((mz_uint32)(((const mz_uint8 *)(p))[0]) |                                   \
  |  |  |  |  773|  1.09k|   ((mz_uint32)(((const mz_uint8 *)(p))[1]) << 8U) |                           \
  |  |  |  |  774|  1.09k|   ((mz_uint32)(((const mz_uint8 *)(p))[2]) << 16U) |                          \
  |  |  |  |  775|  1.09k|   ((mz_uint32)(((const mz_uint8 *)(p))[3]) << 24U))
  |  |  ------------------
  |  |  781|  1.09k|    << 32U))
  ------------------
 6468|  1.09k|            pField_data += sizeof(mz_uint64);
 6469|  1.09k|            field_data_remaining -= sizeof(mz_uint64);
 6470|  1.09k|          }
 6471|       |
 6472|  1.12k|          if (pStat->m_local_header_ofs == MZ_UINT32_MAX) {
  ------------------
  |  |  794|  1.12k|#define MZ_UINT32_MAX (0xFFFFFFFFU)
  ------------------
  |  Branch (6472:15): [True: 302, False: 819]
  ------------------
 6473|    302|            if (field_data_remaining < sizeof(mz_uint64))
  ------------------
  |  Branch (6473:17): [True: 11, False: 291]
  ------------------
 6474|     11|              return mz_zip_set_error(pZip, MZ_ZIP_INVALID_HEADER_OR_CORRUPTED);
 6475|       |
 6476|    291|            pStat->m_local_header_ofs = MZ_READ_LE64(pField_data);
  ------------------
  |  |  779|    291|  (((mz_uint64)MZ_READ_LE32(p)) |                                              \
  |  |  ------------------
  |  |  |  |  772|    291|  ((mz_uint32)(((const mz_uint8 *)(p))[0]) |                                   \
  |  |  |  |  773|    291|   ((mz_uint32)(((const mz_uint8 *)(p))[1]) << 8U) |                           \
  |  |  |  |  774|    291|   ((mz_uint32)(((const mz_uint8 *)(p))[2]) << 16U) |                          \
  |  |  |  |  775|    291|   ((mz_uint32)(((const mz_uint8 *)(p))[3]) << 24U))
  |  |  ------------------
  |  |  780|    291|   (((mz_uint64)MZ_READ_LE32((const mz_uint8 *)(p) + sizeof(mz_uint32)))       \
  |  |  ------------------
  |  |  |  |  772|    291|  ((mz_uint32)(((const mz_uint8 *)(p))[0]) |                                   \
  |  |  |  |  773|    291|   ((mz_uint32)(((const mz_uint8 *)(p))[1]) << 8U) |                           \
  |  |  |  |  774|    291|   ((mz_uint32)(((const mz_uint8 *)(p))[2]) << 16U) |                          \
  |  |  |  |  775|    291|   ((mz_uint32)(((const mz_uint8 *)(p))[3]) << 24U))
  |  |  ------------------
  |  |  781|    291|    << 32U))
  ------------------
 6477|    291|            pField_data += sizeof(mz_uint64);
 6478|    291|            field_data_remaining -= sizeof(mz_uint64);
 6479|    291|          }
 6480|       |
 6481|  1.11k|          break;
 6482|  1.12k|        }
 6483|       |
 6484|  2.64k|        pExtra_data += sizeof(mz_uint16) * 2 + field_data_size;
 6485|  2.64k|        extra_size_remaining =
 6486|  2.64k|            extra_size_remaining - sizeof(mz_uint16) * 2 - field_data_size;
 6487|  2.64k|      } while (extra_size_remaining);
  ------------------
  |  Branch (6487:16): [True: 1.71k, False: 926]
  ------------------
 6488|  2.37k|    }
 6489|  4.18k|  }
 6490|       |
 6491|  7.65k|  return MZ_TRUE;
  ------------------
  |  |  719|  7.65k|#define MZ_TRUE (1)
  ------------------
 6492|  7.99k|}
zip.c:mz_zip_dos_to_time_t:
 5435|  7.99k|static MZ_TIME_T mz_zip_dos_to_time_t(int dos_time, int dos_date) {
 5436|  7.99k|  struct tm tm;
 5437|  7.99k|  memset(&tm, 0, sizeof(tm));
 5438|  7.99k|  tm.tm_isdst = -1;
 5439|  7.99k|  tm.tm_year = ((dos_date >> 9) & 127) + 1980 - 1900;
 5440|  7.99k|  tm.tm_mon = ((dos_date >> 5) & 15) - 1;
 5441|  7.99k|  tm.tm_mday = dos_date & 31;
 5442|  7.99k|  tm.tm_hour = (dos_time >> 11) & 31;
 5443|  7.99k|  tm.tm_min = (dos_time >> 5) & 63;
 5444|  7.99k|  tm.tm_sec = (dos_time << 1) & 62;
 5445|  7.99k|  return mktime(&tm);
 5446|  7.99k|}
zip.c:mz_zip_array_resize:
 5406|  8.91k|                                                  mz_uint growing) {
 5407|  8.91k|  if (new_size > pArray->m_capacity) {
  ------------------
  |  Branch (5407:7): [True: 8.91k, False: 0]
  ------------------
 5408|  8.91k|    if (!mz_zip_array_ensure_capacity(pZip, pArray, new_size, growing))
  ------------------
  |  Branch (5408:9): [True: 0, False: 8.91k]
  ------------------
 5409|      0|      return MZ_FALSE;
  ------------------
  |  |  718|      0|#define MZ_FALSE (0)
  ------------------
 5410|  8.91k|  }
 5411|  8.91k|  pArray->m_size = new_size;
 5412|  8.91k|  return MZ_TRUE;
  ------------------
  |  |  719|  8.91k|#define MZ_TRUE (1)
  ------------------
 5413|  8.91k|}
zip.c:mz_zip_array_ensure_capacity:
 5373|  8.91k|                                            mz_uint growing) {
 5374|  8.91k|  void *pNew_p;
 5375|  8.91k|  size_t new_capacity = min_new_capacity;
 5376|  8.91k|  MZ_ASSERT(pArray->m_element_size);
  ------------------
  |  |  746|  8.91k|#define MZ_ASSERT(x) assert(x)
  ------------------
 5377|  8.91k|  if (pArray->m_capacity >= min_new_capacity)
  ------------------
  |  Branch (5377:7): [True: 0, False: 8.91k]
  ------------------
 5378|      0|    return MZ_TRUE;
  ------------------
  |  |  719|      0|#define MZ_TRUE (1)
  ------------------
 5379|  8.91k|  if (growing) {
  ------------------
  |  Branch (5379:7): [True: 0, False: 8.91k]
  ------------------
 5380|      0|    new_capacity = MZ_MAX(1, pArray->m_capacity);
  ------------------
  |  |  758|      0|#define MZ_MAX(a, b) (((a) > (b)) ? (a) : (b))
  |  |  ------------------
  |  |  |  Branch (758:23): [True: 0, False: 0]
  |  |  ------------------
  ------------------
 5381|      0|    while (new_capacity < min_new_capacity)
  ------------------
  |  Branch (5381:12): [True: 0, False: 0]
  ------------------
 5382|      0|      new_capacity *= 2;
 5383|      0|  }
 5384|  8.91k|  if (NULL == (pNew_p = pZip->m_pRealloc(pZip->m_pAlloc_opaque, pArray->m_p,
  ------------------
  |  Branch (5384:7): [True: 0, False: 8.91k]
  ------------------
 5385|  8.91k|                                         pArray->m_element_size, new_capacity)))
 5386|      0|    return MZ_FALSE;
  ------------------
  |  |  718|      0|#define MZ_FALSE (0)
  ------------------
 5387|  8.91k|  pArray->m_p = pNew_p;
 5388|  8.91k|  pArray->m_capacity = new_capacity;
 5389|  8.91k|  return MZ_TRUE;
  ------------------
  |  |  719|  8.91k|#define MZ_TRUE (1)
  ------------------
 5390|  8.91k|}
zip.c:mz_zip_array_clear:
 5365|  11.4k|                                              mz_zip_array *pArray) {
 5366|  11.4k|  pZip->m_pFree(pZip->m_pAlloc_opaque, pArray->m_p);
 5367|  11.4k|  memset(pArray, 0, sizeof(mz_zip_array));
 5368|  11.4k|}

zip_close:
 1092|  2.55k|void zip_close(struct zip_t *zip) {
 1093|  2.55k|  if (zip) {
  ------------------
  |  Branch (1093:7): [True: 2.55k, False: 0]
  ------------------
 1094|  2.55k|    mz_zip_archive *pZip = &(zip->archive);
 1095|       |    // Always finalize, even if adding failed for some reason, so we have a
 1096|       |    // valid central directory.
 1097|  2.55k|    if (pZip->m_zip_mode == MZ_ZIP_MODE_WRITING) {
  ------------------
  |  Branch (1097:9): [True: 0, False: 2.55k]
  ------------------
 1098|      0|      mz_zip_writer_finalize_archive(pZip);
 1099|      0|    }
 1100|       |
 1101|  2.55k|    if (pZip->m_zip_mode == MZ_ZIP_MODE_WRITING ||
  ------------------
  |  Branch (1101:9): [True: 0, False: 2.55k]
  ------------------
 1102|  2.55k|        pZip->m_zip_mode == MZ_ZIP_MODE_WRITING_HAS_BEEN_FINALIZED) {
  ------------------
  |  Branch (1102:9): [True: 0, False: 2.55k]
  ------------------
 1103|      0|      zip_archive_truncate(pZip);
 1104|      0|      mz_zip_writer_end(pZip);
 1105|  2.55k|    } else if (pZip->m_zip_mode == MZ_ZIP_MODE_READING) {
  ------------------
  |  Branch (1105:16): [True: 2.55k, False: 0]
  ------------------
 1106|  2.55k|      mz_zip_reader_end(pZip);
 1107|  2.55k|    }
 1108|       |
 1109|       |    CLEANUP(zip);
  ------------------
  |  |   67|  2.55k|  do {                                                                         \
  |  |   68|  2.55k|    if (ptr) {                                                                 \
  |  |  ------------------
  |  |  |  Branch (68:9): [True: 2.55k, False: 0]
  |  |  ------------------
  |  |   69|  2.55k|      free((void *)ptr);                                                       \
  |  |   70|  2.55k|      ptr = NULL;                                                              \
  |  |   71|  2.55k|    }                                                                          \
  |  |   72|  2.55k|  } while (0)
  |  |  ------------------
  |  |  |  Branch (72:12): [Folded, False: 2.55k]
  |  |  ------------------
  ------------------
 1110|  2.55k|  }
 1111|  2.55k|}
zip_entry_opencasesensitive:
 1340|  3.38k|int zip_entry_opencasesensitive(struct zip_t *zip, const char *entryname) {
 1341|  3.38k|  return _zip_entry_open(zip, entryname, 1);
 1342|  3.38k|}
zip_entry_openbyindex:
 1344|  3.90k|int zip_entry_openbyindex(struct zip_t *zip, size_t index) {
 1345|  3.90k|  mz_zip_archive *pZip = NULL;
 1346|  3.90k|  mz_zip_archive_file_stat stats;
 1347|  3.90k|  mz_uint namelen;
 1348|  3.90k|  const mz_uint8 *pHeader;
 1349|  3.90k|  const char *pFilename;
 1350|       |
 1351|  3.90k|  if (!zip) {
  ------------------
  |  Branch (1351:7): [True: 0, False: 3.90k]
  ------------------
 1352|       |    // zip_t handler is not initialized
 1353|      0|    return ZIP_ENOINIT;
  ------------------
  |  |   67|      0|#define ZIP_ENOINIT -1      // not initialized
  ------------------
 1354|      0|  }
 1355|       |
 1356|  3.90k|  pZip = &(zip->archive);
 1357|  3.90k|  if (pZip->m_zip_mode != MZ_ZIP_MODE_READING) {
  ------------------
  |  Branch (1357:7): [True: 0, False: 3.90k]
  ------------------
 1358|       |    // open by index requires readonly mode
 1359|      0|    return ZIP_EINVMODE;
  ------------------
  |  |   70|      0|#define ZIP_EINVMODE -4     // invalid zip mode
  ------------------
 1360|      0|  }
 1361|       |
 1362|  3.90k|  if (index >= (size_t)pZip->m_total_files) {
  ------------------
  |  Branch (1362:7): [True: 0, False: 3.90k]
  ------------------
 1363|       |    // index out of range
 1364|      0|    return ZIP_EINVIDX;
  ------------------
  |  |   76|      0|#define ZIP_EINVIDX -10     // invalid index
  ------------------
 1365|      0|  }
 1366|       |
 1367|  3.90k|  if (!(pHeader = &MZ_ZIP_ARRAY_ELEMENT(
  ------------------
  |  | 5355|  3.90k|  ((element_type *)((array_ptr)->m_p))[index]
  ------------------
  |  Branch (1367:7): [True: 0, False: 3.90k]
  ------------------
 1368|  3.90k|            &pZip->m_pState->m_central_dir, mz_uint8,
 1369|  3.90k|            MZ_ZIP_ARRAY_ELEMENT(&pZip->m_pState->m_central_dir_offsets,
 1370|  3.90k|                                 mz_uint32, (mz_uint)index)))) {
 1371|       |    // cannot find header in central directory
 1372|      0|    return ZIP_ENOHDR;
  ------------------
  |  |   77|      0|#define ZIP_ENOHDR -11      // header not found
  ------------------
 1373|      0|  }
 1374|       |
 1375|  3.90k|  namelen = MZ_READ_LE16(pHeader + MZ_ZIP_CDH_FILENAME_LEN_OFS);
  ------------------
  |  |  769|  3.90k|  ((mz_uint32)(((const mz_uint8 *)(p))[0]) |                                   \
  |  |  770|  3.90k|   ((mz_uint32)(((const mz_uint8 *)(p))[1]) << 8U))
  ------------------
 1376|  3.90k|  pFilename = (const char *)pHeader + MZ_ZIP_CENTRAL_DIR_HEADER_SIZE;
 1377|       |
 1378|  3.90k|  if (zip->entry.name) {
  ------------------
  |  Branch (1378:7): [True: 0, False: 3.90k]
  ------------------
 1379|      0|    CLEANUP(zip->entry.name);
  ------------------
  |  |   67|      0|  do {                                                                         \
  |  |   68|      0|    if (ptr) {                                                                 \
  |  |  ------------------
  |  |  |  Branch (68:9): [True: 0, False: 0]
  |  |  ------------------
  |  |   69|      0|      free((void *)ptr);                                                       \
  |  |   70|      0|      ptr = NULL;                                                              \
  |  |   71|      0|    }                                                                          \
  |  |   72|      0|  } while (0)
  |  |  ------------------
  |  |  |  Branch (72:12): [Folded, False: 0]
  |  |  ------------------
  ------------------
 1380|      0|  }
 1381|       |
 1382|  3.90k|  zip->entry.name = zip_strclone(pFilename, namelen);
 1383|  3.90k|  if (!zip->entry.name) {
  ------------------
  |  Branch (1383:7): [True: 0, False: 3.90k]
  ------------------
 1384|       |    // local entry name is NULL
 1385|      0|    return ZIP_EINVENTNAME;
  ------------------
  |  |   68|      0|#define ZIP_EINVENTNAME -2  // invalid entry name
  ------------------
 1386|      0|  }
 1387|       |
 1388|  3.90k|  if (!mz_zip_reader_file_stat(pZip, (mz_uint)index, &stats)) {
  ------------------
  |  Branch (1388:7): [True: 326, False: 3.58k]
  ------------------
 1389|    326|    return ZIP_ENOENT;
  ------------------
  |  |   69|    326|#define ZIP_ENOENT -3       // entry not found
  ------------------
 1390|    326|  }
 1391|       |
 1392|  3.58k|  zip->entry.index = (ssize_t)index;
 1393|  3.58k|  zip->entry.comp_size = stats.m_comp_size;
 1394|  3.58k|  zip->entry.uncomp_size = stats.m_uncomp_size;
 1395|  3.58k|  zip->entry.uncomp_crc32 = stats.m_crc32;
 1396|  3.58k|  zip->entry.dir_offset = stats.m_central_dir_ofs;
 1397|  3.58k|  zip->entry.header_offset = stats.m_local_header_ofs;
 1398|  3.58k|  zip->entry.method = stats.m_method;
 1399|  3.58k|  zip->entry.external_attr = stats.m_external_attr;
 1400|  3.58k|#ifndef MINIZ_NO_TIME
 1401|  3.58k|  zip->entry.m_time = stats.m_time;
 1402|  3.58k|#endif
 1403|       |
 1404|  3.58k|  return 0;
 1405|  3.90k|}
zip_entry_close:
 1407|  6.40k|int zip_entry_close(struct zip_t *zip) {
 1408|  6.40k|  mz_zip_archive *pzip = NULL;
 1409|  6.40k|  mz_uint level;
 1410|  6.40k|  tdefl_status done;
 1411|  6.40k|  mz_uint16 entrylen;
 1412|  6.40k|  mz_uint16 dos_time = 0, dos_date = 0;
 1413|  6.40k|  int err = 0;
 1414|  6.40k|  mz_uint8 *pExtra_data = NULL;
 1415|  6.40k|  mz_uint32 extra_size = 0;
 1416|  6.40k|  mz_uint8 extra_data[MZ_ZIP64_MAX_CENTRAL_EXTRA_FIELD_SIZE];
 1417|  6.40k|  mz_uint8 local_dir_footer[MZ_ZIP_DATA_DESCRIPTER_SIZE64];
 1418|  6.40k|  mz_uint32 local_dir_footer_size = MZ_ZIP_DATA_DESCRIPTER_SIZE64;
 1419|       |
 1420|  6.40k|  if (!zip) {
  ------------------
  |  Branch (1420:7): [True: 0, False: 6.40k]
  ------------------
 1421|       |    // zip_t handler is not initialized
 1422|      0|    err = ZIP_ENOINIT;
  ------------------
  |  |   67|      0|#define ZIP_ENOINIT -1      // not initialized
  ------------------
 1423|      0|    goto cleanup;
 1424|      0|  }
 1425|       |
 1426|  6.40k|  pzip = &(zip->archive);
 1427|  6.40k|  if (pzip->m_zip_mode == MZ_ZIP_MODE_READING) {
  ------------------
  |  Branch (1427:7): [True: 6.40k, False: 0]
  ------------------
 1428|  6.40k|    goto cleanup;
 1429|  6.40k|  }
 1430|       |
 1431|      0|  level = zip->level & 0xF;
 1432|      0|  if (level) {
  ------------------
  |  Branch (1432:7): [True: 0, False: 0]
  ------------------
 1433|      0|    done = tdefl_compress_buffer(&(zip->entry.comp), "", 0, TDEFL_FINISH);
 1434|      0|    if (done != TDEFL_STATUS_DONE && done != TDEFL_STATUS_OKAY) {
  ------------------
  |  Branch (1434:9): [True: 0, False: 0]
  |  Branch (1434:38): [True: 0, False: 0]
  ------------------
 1435|       |      // Cannot flush compressed buffer
 1436|      0|      err = ZIP_ETDEFLBUF;
  ------------------
  |  |   78|      0|#define ZIP_ETDEFLBUF -12   // cannot flush tdefl buffer
  ------------------
 1437|      0|      goto cleanup;
 1438|      0|    }
 1439|      0|    zip->entry.comp_size = zip->entry.state.m_comp_size;
 1440|      0|    zip->entry.dir_offset = zip->entry.state.m_cur_archive_file_ofs;
 1441|      0|    zip->entry.method = MZ_DEFLATED;
  ------------------
  |  |  316|      0|#define MZ_DEFLATED 8
  ------------------
 1442|      0|  }
 1443|       |
 1444|      0|  entrylen = (mz_uint16)strlen(zip->entry.name);
 1445|      0|#ifndef MINIZ_NO_TIME
 1446|      0|  mz_zip_time_t_to_dos_time(zip->entry.m_time, &dos_time, &dos_date);
 1447|      0|#endif
 1448|       |
 1449|      0|  MZ_WRITE_LE32(local_dir_footer + 0, MZ_ZIP_DATA_DESCRIPTOR_ID);
  ------------------
  |  | 7902|      0|#define MZ_WRITE_LE32(p, v) mz_write_le32((mz_uint8 *)(p), (mz_uint32)(v))
  ------------------
 1450|      0|  MZ_WRITE_LE32(local_dir_footer + 4, zip->entry.uncomp_crc32);
  ------------------
  |  | 7902|      0|#define MZ_WRITE_LE32(p, v) mz_write_le32((mz_uint8 *)(p), (mz_uint32)(v))
  ------------------
 1451|      0|  MZ_WRITE_LE64(local_dir_footer + 8, zip->entry.comp_size);
  ------------------
  |  | 7903|      0|#define MZ_WRITE_LE64(p, v) mz_write_le64((mz_uint8 *)(p), (mz_uint64)(v))
  ------------------
 1452|      0|  MZ_WRITE_LE64(local_dir_footer + 16, zip->entry.uncomp_size);
  ------------------
  |  | 7903|      0|#define MZ_WRITE_LE64(p, v) mz_write_le64((mz_uint8 *)(p), (mz_uint64)(v))
  ------------------
 1453|       |
 1454|      0|  if (pzip->m_pWrite(pzip->m_pIO_opaque, zip->entry.dir_offset,
  ------------------
  |  Branch (1454:7): [True: 0, False: 0]
  ------------------
 1455|      0|                     local_dir_footer,
 1456|      0|                     local_dir_footer_size) != local_dir_footer_size) {
 1457|       |    // Cannot write zip entry header
 1458|      0|    err = ZIP_EWRTHDR;
  ------------------
  |  |   80|      0|#define ZIP_EWRTHDR -14     // cannot write entry header
  ------------------
 1459|      0|    goto cleanup;
 1460|      0|  }
 1461|      0|  zip->entry.dir_offset += local_dir_footer_size;
 1462|       |
 1463|      0|  pExtra_data = extra_data;
 1464|      0|  extra_size = mz_zip_writer_create_zip64_extra_data(
 1465|      0|      extra_data,
 1466|      0|      (zip->entry.uncomp_size >= MZ_UINT32_MAX) ? &zip->entry.uncomp_size
  ------------------
  |  |  794|      0|#define MZ_UINT32_MAX (0xFFFFFFFFU)
  ------------------
  |  Branch (1466:7): [True: 0, False: 0]
  ------------------
 1467|      0|                                                : NULL,
 1468|      0|      (zip->entry.comp_size >= MZ_UINT32_MAX) ? &zip->entry.comp_size : NULL,
  ------------------
  |  |  794|      0|#define MZ_UINT32_MAX (0xFFFFFFFFU)
  ------------------
  |  Branch (1468:7): [True: 0, False: 0]
  ------------------
 1469|      0|      (zip->entry.header_offset >= MZ_UINT32_MAX) ? &zip->entry.header_offset
  ------------------
  |  |  794|      0|#define MZ_UINT32_MAX (0xFFFFFFFFU)
  ------------------
  |  Branch (1469:7): [True: 0, False: 0]
  ------------------
 1470|      0|                                                  : NULL);
 1471|       |
 1472|      0|  if ((entrylen) && ISSLASH(zip->entry.name[entrylen - 1]) &&
  ------------------
  |  |   63|      0|#define ISSLASH(C) ((C) == '/' || (C) == '\\')
  |  |  ------------------
  |  |  |  Branch (63:21): [True: 0, False: 0]
  |  |  |  Branch (63:35): [True: 0, False: 0]
  |  |  ------------------
  ------------------
  |  Branch (1472:7): [True: 0, False: 0]
  ------------------
 1473|      0|      !zip->entry.uncomp_size) {
  ------------------
  |  Branch (1473:7): [True: 0, False: 0]
  ------------------
 1474|       |    /* Set DOS Subdirectory attribute bit. */
 1475|      0|    zip->entry.external_attr |= MZ_ZIP_DOS_DIR_ATTRIBUTE_BITFLAG;
 1476|      0|  }
 1477|       |
 1478|      0|  if (!mz_zip_writer_add_to_central_dir(
  ------------------
  |  Branch (1478:7): [True: 0, False: 0]
  ------------------
 1479|      0|          pzip, zip->entry.name, entrylen, pExtra_data, (mz_uint16)extra_size,
 1480|      0|          "", 0, zip->entry.uncomp_size, zip->entry.comp_size,
 1481|      0|          zip->entry.uncomp_crc32, zip->entry.method,
 1482|      0|          MZ_ZIP_GENERAL_PURPOSE_BIT_FLAG_UTF8 |
 1483|      0|              MZ_ZIP_LDH_BIT_FLAG_HAS_LOCATOR,
 1484|      0|          dos_time, dos_date, zip->entry.header_offset,
 1485|      0|          zip->entry.external_attr, NULL, 0)) {
 1486|       |    // Cannot write to zip central dir
 1487|      0|    err = ZIP_EWRTDIR;
  ------------------
  |  |   81|      0|#define ZIP_EWRTDIR -15     // cannot write to central dir
  ------------------
 1488|      0|    goto cleanup;
 1489|      0|  }
 1490|       |
 1491|      0|  pzip->m_total_files++;
 1492|      0|  pzip->m_archive_size = zip->entry.dir_offset;
 1493|       |
 1494|  6.40k|cleanup:
 1495|  6.40k|  if (zip) {
  ------------------
  |  Branch (1495:7): [True: 6.40k, False: 0]
  ------------------
 1496|  6.40k|    zip->entry.m_time = 0;
 1497|  6.40k|    zip->entry.index = -1;
 1498|       |    CLEANUP(zip->entry.name);
  ------------------
  |  |   67|  6.40k|  do {                                                                         \
  |  |   68|  6.40k|    if (ptr) {                                                                 \
  |  |  ------------------
  |  |  |  Branch (68:9): [True: 6.40k, False: 0]
  |  |  ------------------
  |  |   69|  6.40k|      free((void *)ptr);                                                       \
  |  |   70|  6.40k|      ptr = NULL;                                                              \
  |  |   71|  6.40k|    }                                                                          \
  |  |   72|  6.40k|  } while (0)
  |  |  ------------------
  |  |  |  Branch (72:12): [Folded, False: 6.40k]
  |  |  ------------------
  ------------------
 1499|  6.40k|  }
 1500|  6.40k|  return err;
 1501|      0|}
zip_entry_name:
 1503|  3.90k|const char *zip_entry_name(struct zip_t *zip) {
 1504|  3.90k|  if (!zip) {
  ------------------
  |  Branch (1504:7): [True: 0, False: 3.90k]
  ------------------
 1505|       |    // zip_t handler is not initialized
 1506|      0|    return NULL;
 1507|      0|  }
 1508|  3.90k|  return zip->entry.name;
 1509|  3.90k|}
zip_entry_isdir:
 1520|  3.90k|int zip_entry_isdir(struct zip_t *zip) {
 1521|  3.90k|  mz_uint16 entrylen;
 1522|  3.90k|  if (!zip) {
  ------------------
  |  Branch (1522:7): [True: 0, False: 3.90k]
  ------------------
 1523|       |    // zip_t handler is not initialized
 1524|      0|    return ZIP_ENOINIT;
  ------------------
  |  |   67|      0|#define ZIP_ENOINIT -1      // not initialized
  ------------------
 1525|      0|  }
 1526|       |
 1527|  3.90k|  if (zip->entry.index < (ssize_t)0) {
  ------------------
  |  Branch (1527:7): [True: 326, False: 3.58k]
  ------------------
 1528|       |    // zip entry is not opened
 1529|    326|    return ZIP_EINVIDX;
  ------------------
  |  |   76|    326|#define ZIP_EINVIDX -10     // invalid index
  ------------------
 1530|    326|  }
 1531|       |
 1532|  3.58k|  if (!zip->entry.name) {
  ------------------
  |  Branch (1532:7): [True: 0, False: 3.58k]
  ------------------
 1533|      0|    return ZIP_EINVENTNAME;
  ------------------
  |  |   68|      0|#define ZIP_EINVENTNAME -2  // invalid entry name
  ------------------
 1534|      0|  }
 1535|       |
 1536|  3.58k|  entrylen = (mz_uint16)strlen(zip->entry.name);
 1537|  3.58k|  if (entrylen == 0) {
  ------------------
  |  Branch (1537:7): [True: 321, False: 3.26k]
  ------------------
 1538|    321|    return 0;
 1539|    321|  }
 1540|  3.26k|  return ISSLASH(zip->entry.name[entrylen - 1]);
  ------------------
  |  |   63|  3.26k|#define ISSLASH(C) ((C) == '/' || (C) == '\\')
  |  |  ------------------
  |  |  |  Branch (63:21): [True: 41, False: 3.21k]
  |  |  |  Branch (63:35): [True: 153, False: 3.06k]
  |  |  ------------------
  ------------------
 1541|  3.58k|}
zip_entry_size:
 1543|  6.40k|unsigned long long zip_entry_size(struct zip_t *zip) {
 1544|  6.40k|  return zip_entry_uncomp_size(zip);
 1545|  6.40k|}
zip_entry_uncomp_size:
 1547|  6.40k|unsigned long long zip_entry_uncomp_size(struct zip_t *zip) {
 1548|  6.40k|  return zip ? zip->entry.uncomp_size : 0;
  ------------------
  |  Branch (1548:10): [True: 6.40k, False: 0]
  ------------------
 1549|  6.40k|}
zip_entry_comp_size:
 1551|  6.40k|unsigned long long zip_entry_comp_size(struct zip_t *zip) {
 1552|  6.40k|  return zip ? zip->entry.comp_size : 0;
  ------------------
  |  Branch (1552:10): [True: 6.40k, False: 0]
  ------------------
 1553|  6.40k|}
zip_entry_noallocread:
 1702|  1.57k|ssize_t zip_entry_noallocread(struct zip_t *zip, void *buf, size_t bufsize) {
 1703|  1.57k|  mz_zip_archive *pzip = NULL;
 1704|       |
 1705|  1.57k|  if (!zip) {
  ------------------
  |  Branch (1705:7): [True: 0, False: 1.57k]
  ------------------
 1706|       |    // zip_t handler is not initialized
 1707|      0|    return (ssize_t)ZIP_ENOINIT;
  ------------------
  |  |   67|      0|#define ZIP_ENOINIT -1      // not initialized
  ------------------
 1708|      0|  }
 1709|       |
 1710|  1.57k|  pzip = &(zip->archive);
 1711|  1.57k|  if (pzip->m_zip_mode != MZ_ZIP_MODE_READING ||
  ------------------
  |  Branch (1711:7): [True: 0, False: 1.57k]
  ------------------
 1712|  1.57k|      zip->entry.index < (ssize_t)0) {
  ------------------
  |  Branch (1712:7): [True: 0, False: 1.57k]
  ------------------
 1713|       |    // the entry is not found or we do not have read access
 1714|      0|    return (ssize_t)ZIP_ENOENT;
  ------------------
  |  |   69|      0|#define ZIP_ENOENT -3       // entry not found
  ------------------
 1715|      0|  }
 1716|       |
 1717|  1.57k|  if (!mz_zip_reader_extract_to_mem_no_alloc(pzip, (mz_uint)zip->entry.index,
  ------------------
  |  Branch (1717:7): [True: 1.20k, False: 369]
  ------------------
 1718|  1.57k|                                             buf, bufsize, 0, NULL, 0)) {
 1719|  1.20k|    return (ssize_t)ZIP_EMEMNOALLOC;
  ------------------
  |  |   84|  1.20k|#define ZIP_EMEMNOALLOC -18 // extracting data using no memory allocation
  ------------------
 1720|  1.20k|  }
 1721|       |
 1722|    369|  return (ssize_t)zip->entry.uncomp_size;
 1723|  1.57k|}
zip_entries_total:
 1867|  3.83k|ssize_t zip_entries_total(struct zip_t *zip) {
 1868|  3.83k|  if (!zip) {
  ------------------
  |  Branch (1868:7): [True: 1.27k, False: 2.55k]
  ------------------
 1869|       |    // zip_t handler is not initialized
 1870|  1.27k|    return ZIP_ENOINIT;
  ------------------
  |  |   67|  1.27k|#define ZIP_ENOINIT -1      // not initialized
  ------------------
 1871|  1.27k|  }
 1872|       |
 1873|  2.55k|  return (ssize_t)zip->archive.m_total_files;
 1874|  3.83k|}
zip_stream_open:
 1970|  3.83k|                              char mode) {
 1971|  3.83k|  int errnum = 0;
 1972|  3.83k|  return zip_stream_openwitherror(stream, size, level, mode, &errnum);
 1973|  3.83k|}
zip_stream_openwitherror:
 1976|  3.83k|                                       int level, char mode, int *errnum) {
 1977|  3.83k|  mz_uint wflags = (mode == 'w') ? MZ_ZIP_FLAG_WRITE_ZIP64 : 0;
  ------------------
  |  Branch (1977:20): [True: 0, False: 3.83k]
  ------------------
 1978|  3.83k|  struct zip_t *zip = (struct zip_t *)calloc((size_t)1, sizeof(struct zip_t));
 1979|  3.83k|  if (!zip) {
  ------------------
  |  Branch (1979:7): [True: 0, False: 3.83k]
  ------------------
 1980|       |    // out of memory
 1981|      0|    *errnum = ZIP_EOOMEM;
  ------------------
  |  |   87|      0|#define ZIP_EOOMEM -21      // out of memory
  ------------------
 1982|      0|    return NULL;
 1983|      0|  }
 1984|       |
 1985|  3.83k|  zip->entry.index = -1;
 1986|       |
 1987|  3.83k|  if (level < 0) {
  ------------------
  |  Branch (1987:7): [True: 0, False: 3.83k]
  ------------------
 1988|      0|    level = MZ_DEFAULT_LEVEL;
 1989|      0|  }
 1990|  3.83k|  if ((level & 0xF) > MZ_UBER_COMPRESSION) {
  ------------------
  |  Branch (1990:7): [True: 0, False: 3.83k]
  ------------------
 1991|       |    // Wrong compression level
 1992|      0|    *errnum = ZIP_EINVLVL;
  ------------------
  |  |   71|      0|#define ZIP_EINVLVL -5      // invalid compression level
  ------------------
 1993|      0|    goto cleanup;
 1994|      0|  }
 1995|  3.83k|  zip->level = (mz_uint)level;
 1996|       |
 1997|  3.83k|  switch (mode) {
 1998|  3.83k|  case 'r':
  ------------------
  |  Branch (1998:3): [True: 3.83k, False: 0]
  ------------------
 1999|  3.83k|  case ('r' - 64): {
  ------------------
  |  Branch (1999:3): [True: 0, False: 3.83k]
  ------------------
 2000|  3.83k|    if (stream && size > 0) {
  ------------------
  |  Branch (2000:9): [True: 3.83k, False: 0]
  |  Branch (2000:19): [True: 3.83k, False: 0]
  ------------------
 2001|  3.83k|      if (!mz_zip_reader_init_mem(&(zip->archive), stream, size, 0)) {
  ------------------
  |  Branch (2001:11): [True: 1.27k, False: 2.55k]
  ------------------
 2002|  1.27k|        *errnum = ZIP_ERINIT;
  ------------------
  |  |   96|  1.27k|#define ZIP_ERINIT -30      // cannot initialize reader
  ------------------
 2003|  1.27k|        goto cleanup;
 2004|  1.27k|      }
 2005|  3.83k|    } else {
 2006|      0|      *errnum = ZIP_EINVMODE;
  ------------------
  |  |   70|      0|#define ZIP_EINVMODE -4     // invalid zip mode
  ------------------
 2007|      0|      goto cleanup;
 2008|      0|    }
 2009|  3.83k|  } break;
 2010|       |
 2011|  2.55k|  case 'd':
  ------------------
  |  Branch (2011:3): [True: 0, False: 3.83k]
  ------------------
 2012|      0|  case ('d' - 64): {
  ------------------
  |  Branch (2012:3): [True: 0, False: 3.83k]
  ------------------
 2013|      0|    if (stream && size > 0) {
  ------------------
  |  Branch (2013:9): [True: 0, False: 0]
  |  Branch (2013:19): [True: 0, False: 0]
  ------------------
 2014|      0|      if (!mz_zip_reader_init_mem(
  ------------------
  |  Branch (2014:11): [True: 0, False: 0]
  ------------------
 2015|      0|              &(zip->archive), stream, size,
 2016|      0|              zip->level | MZ_ZIP_FLAG_DO_NOT_SORT_CENTRAL_DIRECTORY)) {
 2017|      0|        *errnum = ZIP_ERINIT;
  ------------------
  |  |   96|      0|#define ZIP_ERINIT -30      // cannot initialize reader
  ------------------
 2018|      0|        goto cleanup;
 2019|      0|      }
 2020|      0|      if (!mz_zip_writer_init_from_reader_v2(&(zip->archive), NULL, 0)) {
  ------------------
  |  Branch (2020:11): [True: 0, False: 0]
  ------------------
 2021|      0|        *errnum = ZIP_EWRINIT;
  ------------------
  |  |   98|      0|#define ZIP_EWRINIT -32     // cannot initialize writer from reader
  ------------------
 2022|      0|        mz_zip_reader_end(&(zip->archive));
 2023|      0|        goto cleanup;
 2024|      0|      }
 2025|      0|      zip->archive.m_pWrite = zip_stream_delete_write_func;
 2026|      0|    } else {
 2027|      0|      *errnum = ZIP_EINVMODE;
  ------------------
  |  |   70|      0|#define ZIP_EINVMODE -4     // invalid zip mode
  ------------------
 2028|      0|      goto cleanup;
 2029|      0|    }
 2030|      0|  } break;
 2031|       |
 2032|      0|  case 'w':
  ------------------
  |  Branch (2032:3): [True: 0, False: 3.83k]
  ------------------
 2033|      0|  case ('w' - 64): {
  ------------------
  |  Branch (2033:3): [True: 0, False: 3.83k]
  ------------------
 2034|      0|    if (stream == NULL && size == 0) {
  ------------------
  |  Branch (2034:9): [True: 0, False: 0]
  |  Branch (2034:27): [True: 0, False: 0]
  ------------------
 2035|      0|      if (!mz_zip_writer_init_heap_v2(&(zip->archive), 0, 1024, wflags)) {
  ------------------
  |  Branch (2035:11): [True: 0, False: 0]
  ------------------
 2036|      0|        *errnum = ZIP_EWINIT;
  ------------------
  |  |   97|      0|#define ZIP_EWINIT -31      // cannot initialize writer
  ------------------
 2037|      0|        goto cleanup;
 2038|      0|      }
 2039|      0|    } else {
 2040|      0|      *errnum = ZIP_EINVMODE;
  ------------------
  |  |   70|      0|#define ZIP_EINVMODE -4     // invalid zip mode
  ------------------
 2041|      0|      goto cleanup;
 2042|      0|    }
 2043|      0|  } break;
 2044|       |
 2045|      0|  default:
  ------------------
  |  Branch (2045:3): [True: 0, False: 3.83k]
  ------------------
 2046|      0|    *errnum = ZIP_EINVMODE;
  ------------------
  |  |   70|      0|#define ZIP_EINVMODE -4     // invalid zip mode
  ------------------
 2047|      0|    goto cleanup;
 2048|  3.83k|  }
 2049|       |
 2050|  2.55k|  *errnum = 0;
 2051|  2.55k|  return zip;
 2052|       |
 2053|  1.27k|cleanup:
 2054|  1.27k|  CLEANUP(zip);
  ------------------
  |  |   67|  1.27k|  do {                                                                         \
  |  |   68|  1.27k|    if (ptr) {                                                                 \
  |  |  ------------------
  |  |  |  Branch (68:9): [True: 1.27k, False: 0]
  |  |  ------------------
  |  |   69|  1.27k|      free((void *)ptr);                                                       \
  |  |   70|  1.27k|      ptr = NULL;                                                              \
  |  |   71|  1.27k|    }                                                                          \
  |  |   72|  1.27k|  } while (0)
  |  |  ------------------
  |  |  |  Branch (72:12): [Folded, False: 1.27k]
  |  |  ------------------
  ------------------
 2055|       |  return NULL;
 2056|  3.83k|}
zip.c:_zip_entry_open:
 1133|  3.38k|                           int case_sensitive) {
 1134|  3.38k|  size_t entrylen = 0;
 1135|  3.38k|  mz_zip_archive *pzip = NULL;
 1136|  3.38k|  mz_uint num_alignment_padding_bytes, level;
 1137|  3.38k|  mz_zip_archive_file_stat stats;
 1138|  3.38k|  int err = 0;
 1139|  3.38k|  mz_uint16 dos_time = 0, dos_date = 0;
 1140|  3.38k|  mz_uint32 extra_size = 0;
 1141|  3.38k|  mz_uint8 extra_data[MZ_ZIP64_MAX_CENTRAL_EXTRA_FIELD_SIZE];
 1142|  3.38k|  mz_uint64 local_dir_header_ofs = 0;
 1143|       |
 1144|  3.38k|  if (!zip) {
  ------------------
  |  Branch (1144:7): [True: 0, False: 3.38k]
  ------------------
 1145|      0|    return ZIP_ENOINIT;
  ------------------
  |  |   67|      0|#define ZIP_ENOINIT -1      // not initialized
  ------------------
 1146|      0|  }
 1147|       |
 1148|  3.38k|  local_dir_header_ofs = zip->archive.m_archive_size;
 1149|       |
 1150|  3.38k|  if (!entryname) {
  ------------------
  |  Branch (1150:7): [True: 0, False: 3.38k]
  ------------------
 1151|      0|    return ZIP_EINVENTNAME;
  ------------------
  |  |   68|      0|#define ZIP_EINVENTNAME -2  // invalid entry name
  ------------------
 1152|      0|  }
 1153|       |
 1154|  3.38k|  entrylen = strlen(entryname);
 1155|  3.38k|  if (entrylen == 0) {
  ------------------
  |  Branch (1155:7): [True: 321, False: 3.06k]
  ------------------
 1156|    321|    return ZIP_EINVENTNAME;
  ------------------
  |  |   68|    321|#define ZIP_EINVENTNAME -2  // invalid entry name
  ------------------
 1157|    321|  }
 1158|       |
 1159|  3.06k|  if (zip->entry.name) {
  ------------------
  |  Branch (1159:7): [True: 0, False: 3.06k]
  ------------------
 1160|      0|    CLEANUP(zip->entry.name);
  ------------------
  |  |   67|      0|  do {                                                                         \
  |  |   68|      0|    if (ptr) {                                                                 \
  |  |  ------------------
  |  |  |  Branch (68:9): [True: 0, False: 0]
  |  |  ------------------
  |  |   69|      0|      free((void *)ptr);                                                       \
  |  |   70|      0|      ptr = NULL;                                                              \
  |  |   71|      0|    }                                                                          \
  |  |   72|      0|  } while (0)
  |  |  ------------------
  |  |  |  Branch (72:12): [Folded, False: 0]
  |  |  ------------------
  ------------------
 1161|      0|  }
 1162|       |
 1163|  3.06k|  pzip = &(zip->archive);
 1164|  3.06k|  if (pzip->m_zip_mode == MZ_ZIP_MODE_READING) {
  ------------------
  |  Branch (1164:7): [True: 3.06k, False: 0]
  ------------------
 1165|  3.06k|    zip->entry.name = zip_strclone(entryname, entrylen);
 1166|  3.06k|    if (!zip->entry.name) {
  ------------------
  |  Branch (1166:9): [True: 0, False: 3.06k]
  ------------------
 1167|       |      // Cannot parse zip entry name
 1168|      0|      return ZIP_EINVENTNAME;
  ------------------
  |  |   68|      0|#define ZIP_EINVENTNAME -2  // invalid entry name
  ------------------
 1169|      0|    }
 1170|       |
 1171|  3.06k|    zip->entry.index = (ssize_t)mz_zip_reader_locate_file(
 1172|  3.06k|        pzip, zip->entry.name, NULL,
 1173|  3.06k|        case_sensitive ? MZ_ZIP_FLAG_CASE_SENSITIVE : 0);
  ------------------
  |  Branch (1173:9): [True: 3.06k, False: 0]
  ------------------
 1174|  3.06k|    if (zip->entry.index < (ssize_t)0) {
  ------------------
  |  Branch (1174:9): [True: 548, False: 2.51k]
  ------------------
 1175|    548|      err = ZIP_ENOENT;
  ------------------
  |  |   69|    548|#define ZIP_ENOENT -3       // entry not found
  ------------------
 1176|    548|      goto cleanup;
 1177|    548|    }
 1178|       |
 1179|  2.51k|    if (!mz_zip_reader_file_stat(pzip, (mz_uint)zip->entry.index, &stats)) {
  ------------------
  |  Branch (1179:9): [True: 14, False: 2.50k]
  ------------------
 1180|     14|      err = ZIP_ENOENT;
  ------------------
  |  |   69|     14|#define ZIP_ENOENT -3       // entry not found
  ------------------
 1181|     14|      goto cleanup;
 1182|     14|    }
 1183|       |
 1184|  2.50k|    zip->entry.comp_size = stats.m_comp_size;
 1185|  2.50k|    zip->entry.uncomp_size = stats.m_uncomp_size;
 1186|  2.50k|    zip->entry.uncomp_crc32 = stats.m_crc32;
 1187|  2.50k|    zip->entry.dir_offset = stats.m_central_dir_ofs;
 1188|  2.50k|    zip->entry.header_offset = stats.m_local_header_ofs;
 1189|  2.50k|    zip->entry.method = stats.m_method;
 1190|  2.50k|    zip->entry.external_attr = stats.m_external_attr;
 1191|  2.50k|#ifndef MINIZ_NO_TIME
 1192|  2.50k|    zip->entry.m_time = stats.m_time;
 1193|  2.50k|#endif
 1194|       |
 1195|  2.50k|    return 0;
 1196|  2.51k|  }
 1197|       |
 1198|       |  /*
 1199|       |    .ZIP File Format Specification Version: 6.3.3
 1200|       |
 1201|       |    4.4.17.1 The name of the file, with optional relative path.
 1202|       |    The path stored MUST not contain a drive or
 1203|       |    device letter, or a leading slash.  All slashes
 1204|       |    MUST be forward slashes '/' as opposed to
 1205|       |    backwards slashes '\' for compatibility with Amiga
 1206|       |    and UNIX file systems etc.  If input came from standard
 1207|       |    input, there is no file name field.
 1208|       |  */
 1209|      0|  zip->entry.name = zip_strrpl(entryname, entrylen, '\\', '/');
 1210|      0|  if (!zip->entry.name) {
  ------------------
  |  Branch (1210:7): [True: 0, False: 0]
  ------------------
 1211|       |    // Cannot parse zip entry name
 1212|      0|    return ZIP_EINVENTNAME;
  ------------------
  |  |   68|      0|#define ZIP_EINVENTNAME -2  // invalid entry name
  ------------------
 1213|      0|  }
 1214|       |
 1215|      0|  level = zip->level & 0xF;
 1216|       |
 1217|      0|  zip->entry.index = (ssize_t)zip->archive.m_total_files;
 1218|      0|  zip->entry.comp_size = 0;
 1219|      0|  zip->entry.uncomp_size = 0;
 1220|      0|  zip->entry.uncomp_crc32 = MZ_CRC32_INIT;
  ------------------
  |  |  300|      0|#define MZ_CRC32_INIT (0)
  ------------------
 1221|      0|  zip->entry.dir_offset = zip->archive.m_archive_size;
 1222|      0|  zip->entry.header_offset = zip->archive.m_archive_size;
 1223|      0|  memset(zip->entry.header, 0, MZ_ZIP_LOCAL_DIR_HEADER_SIZE * sizeof(mz_uint8));
 1224|      0|  zip->entry.method = level ? MZ_DEFLATED : 0;
  ------------------
  |  |  316|      0|#define MZ_DEFLATED 8
  ------------------
  |  Branch (1224:23): [True: 0, False: 0]
  ------------------
 1225|       |
 1226|       |  // UNIX or APPLE
 1227|       |#if MZ_PLATFORM == 3 || MZ_PLATFORM == 19
 1228|       |  // regular file with rw-r--r-- permissions
 1229|       |  zip->entry.external_attr = (mz_uint32)(0100644) << 16;
 1230|       |#else
 1231|      0|  zip->entry.external_attr = 0;
 1232|      0|#endif
 1233|       |
 1234|      0|  num_alignment_padding_bytes =
 1235|      0|      mz_zip_writer_compute_padding_needed_for_file_alignment(pzip);
 1236|       |
 1237|      0|  if (!pzip->m_pState || (pzip->m_zip_mode != MZ_ZIP_MODE_WRITING)) {
  ------------------
  |  Branch (1237:7): [True: 0, False: 0]
  |  Branch (1237:26): [True: 0, False: 0]
  ------------------
 1238|       |    // Invalid zip mode
 1239|      0|    err = ZIP_EINVMODE;
  ------------------
  |  |   70|      0|#define ZIP_EINVMODE -4     // invalid zip mode
  ------------------
 1240|      0|    goto cleanup;
 1241|      0|  }
 1242|      0|  if (zip->level & MZ_ZIP_FLAG_COMPRESSED_DATA) {
  ------------------
  |  Branch (1242:7): [True: 0, False: 0]
  ------------------
 1243|       |    // Invalid zip compression level
 1244|      0|    err = ZIP_EINVLVL;
  ------------------
  |  |   71|      0|#define ZIP_EINVLVL -5      // invalid compression level
  ------------------
 1245|      0|    goto cleanup;
 1246|      0|  }
 1247|       |
 1248|      0|  if (!mz_zip_writer_write_zeros(pzip, zip->entry.dir_offset,
  ------------------
  |  Branch (1248:7): [True: 0, False: 0]
  ------------------
 1249|      0|                                 num_alignment_padding_bytes)) {
 1250|       |    // Cannot memset zip entry header
 1251|      0|    err = ZIP_EMEMSET;
  ------------------
  |  |   73|      0|#define ZIP_EMEMSET -7      // memset error
  ------------------
 1252|      0|    goto cleanup;
 1253|      0|  }
 1254|      0|  local_dir_header_ofs += num_alignment_padding_bytes;
 1255|       |
 1256|      0|  zip->entry.m_time = time(NULL);
 1257|      0|#ifndef MINIZ_NO_TIME
 1258|      0|  mz_zip_time_t_to_dos_time(zip->entry.m_time, &dos_time, &dos_date);
 1259|      0|#endif
 1260|       |
 1261|       |  // ZIP64 header with NULL sizes (sizes will be in the data descriptor, just
 1262|       |  // after file data)
 1263|      0|  extra_size = mz_zip_writer_create_zip64_extra_data(
 1264|      0|      extra_data, NULL, NULL,
 1265|      0|      (local_dir_header_ofs >= MZ_UINT32_MAX) ? &local_dir_header_ofs : NULL);
  ------------------
  |  |  794|      0|#define MZ_UINT32_MAX (0xFFFFFFFFU)
  ------------------
  |  Branch (1265:7): [True: 0, False: 0]
  ------------------
 1266|       |
 1267|      0|  if (!mz_zip_writer_create_local_dir_header(
  ------------------
  |  Branch (1267:7): [True: 0, False: 0]
  ------------------
 1268|      0|          pzip, zip->entry.header, (mz_uint16)entrylen, (mz_uint16)extra_size,
 1269|      0|          0, 0, 0, zip->entry.method,
 1270|      0|          MZ_ZIP_GENERAL_PURPOSE_BIT_FLAG_UTF8 |
 1271|      0|              MZ_ZIP_LDH_BIT_FLAG_HAS_LOCATOR,
 1272|      0|          dos_time, dos_date)) {
 1273|       |    // Cannot create zip entry header
 1274|      0|    err = ZIP_EMEMSET;
  ------------------
  |  |   73|      0|#define ZIP_EMEMSET -7      // memset error
  ------------------
 1275|      0|    goto cleanup;
 1276|      0|  }
 1277|       |
 1278|      0|  zip->entry.header_offset =
 1279|      0|      zip->entry.dir_offset + num_alignment_padding_bytes;
 1280|       |
 1281|      0|  if (pzip->m_pWrite(pzip->m_pIO_opaque, zip->entry.header_offset,
  ------------------
  |  Branch (1281:7): [True: 0, False: 0]
  ------------------
 1282|      0|                     zip->entry.header,
 1283|      0|                     sizeof(zip->entry.header)) != sizeof(zip->entry.header)) {
 1284|       |    // Cannot write zip entry header
 1285|      0|    err = ZIP_EMEMSET;
  ------------------
  |  |   73|      0|#define ZIP_EMEMSET -7      // memset error
  ------------------
 1286|      0|    goto cleanup;
 1287|      0|  }
 1288|       |
 1289|      0|  if (pzip->m_file_offset_alignment) {
  ------------------
  |  Branch (1289:7): [True: 0, False: 0]
  ------------------
 1290|      0|    MZ_ASSERT(
  ------------------
  |  |  746|      0|#define MZ_ASSERT(x) assert(x)
  ------------------
 1291|      0|        (zip->entry.header_offset & (pzip->m_file_offset_alignment - 1)) == 0);
 1292|      0|  }
 1293|      0|  zip->entry.dir_offset +=
 1294|      0|      num_alignment_padding_bytes + sizeof(zip->entry.header);
 1295|       |
 1296|      0|  if (pzip->m_pWrite(pzip->m_pIO_opaque, zip->entry.dir_offset, zip->entry.name,
  ------------------
  |  Branch (1296:7): [True: 0, False: 0]
  ------------------
 1297|      0|                     entrylen) != entrylen) {
 1298|       |    // Cannot write data to zip entry
 1299|      0|    err = ZIP_EWRTENT;
  ------------------
  |  |   74|      0|#define ZIP_EWRTENT -8      // cannot write data to entry
  ------------------
 1300|      0|    goto cleanup;
 1301|      0|  }
 1302|       |
 1303|      0|  zip->entry.dir_offset += entrylen;
 1304|       |
 1305|      0|  if (pzip->m_pWrite(pzip->m_pIO_opaque, zip->entry.dir_offset, extra_data,
  ------------------
  |  Branch (1305:7): [True: 0, False: 0]
  ------------------
 1306|      0|                     extra_size) != extra_size) {
 1307|       |    // Cannot write ZIP64 data to zip entry
 1308|      0|    err = ZIP_EWRTENT;
  ------------------
  |  |   74|      0|#define ZIP_EWRTENT -8      // cannot write data to entry
  ------------------
 1309|      0|    goto cleanup;
 1310|      0|  }
 1311|      0|  zip->entry.dir_offset += extra_size;
 1312|       |
 1313|      0|  if (level) {
  ------------------
  |  Branch (1313:7): [True: 0, False: 0]
  ------------------
 1314|      0|    zip->entry.state.m_pZip = pzip;
 1315|      0|    zip->entry.state.m_cur_archive_file_ofs = zip->entry.dir_offset;
 1316|      0|    zip->entry.state.m_comp_size = 0;
 1317|       |
 1318|      0|    if (tdefl_init(&(zip->entry.comp), mz_zip_writer_add_put_buf_callback,
  ------------------
  |  Branch (1318:9): [True: 0, False: 0]
  ------------------
 1319|      0|                   &(zip->entry.state),
 1320|      0|                   (int)tdefl_create_comp_flags_from_zip_params(
 1321|      0|                       (int)level, -15, MZ_DEFAULT_STRATEGY)) !=
 1322|      0|        TDEFL_STATUS_OKAY) {
 1323|       |      // Cannot initialize the zip compressor
 1324|      0|      err = ZIP_ETDEFLINIT;
  ------------------
  |  |   75|      0|#define ZIP_ETDEFLINIT -9   // cannot initialize tdefl compressor
  ------------------
 1325|      0|      goto cleanup;
 1326|      0|    }
 1327|      0|  }
 1328|       |
 1329|      0|  return 0;
 1330|       |
 1331|    562|cleanup:
 1332|       |  CLEANUP(zip->entry.name);
  ------------------
  |  |   67|    562|  do {                                                                         \
  |  |   68|    562|    if (ptr) {                                                                 \
  |  |  ------------------
  |  |  |  Branch (68:9): [True: 562, False: 0]
  |  |  ------------------
  |  |   69|    562|      free((void *)ptr);                                                       \
  |  |   70|    562|      ptr = NULL;                                                              \
  |  |   71|    562|    }                                                                          \
  |  |   72|    562|  } while (0)
  |  |  ------------------
  |  |  |  Branch (72:12): [Folded, False: 562]
  |  |  ------------------
  ------------------
 1333|    562|  return err;
 1334|      0|}
zip.c:zip_strclone:
  270|  6.97k|static char *zip_strclone(const char *str, size_t n) {
  271|  6.97k|  char c;
  272|  6.97k|  size_t i;
  273|  6.97k|  char *rpl = (char *)calloc((1 + n), sizeof(char));
  274|  6.97k|  char *begin = rpl;
  275|  6.97k|  if (!rpl) {
  ------------------
  |  Branch (275:7): [True: 0, False: 6.97k]
  ------------------
  276|      0|    return NULL;
  277|      0|  }
  278|       |
  279|  6.41M|  for (i = 0; (i < n) && (c = *str++); ++i) {
  ------------------
  |  Branch (279:15): [True: 6.41M, False: 5.67k]
  |  Branch (279:26): [True: 6.41M, False: 1.30k]
  ------------------
  280|  6.41M|    *rpl++ = c;
  281|  6.41M|  }
  282|       |
  283|  6.97k|  return begin;
  284|  6.97k|}

LLVMFuzzerTestOneInput:
   43|  3.83k|extern "C" int LLVMFuzzerTestOneInput(const uint8_t *data, size_t size) {
   44|  3.83k|  if (size < 1)
  ------------------
  |  Branch (44:7): [True: 0, False: 3.83k]
  ------------------
   45|      0|    return 0;
   46|       |
   47|  3.83k|  global_init();
   48|       |
   49|  3.83k|  Ogre::String name = "fuzz.zip";
   50|  3.83k|  g_zipFactory->addEmbbeddedFile(name, data, size, nullptr);
   51|       |
   52|  3.83k|  Ogre::Archive *arch = g_zipFactory->createInstance(name, true);
   53|  3.83k|  if (arch) {
  ------------------
  |  Branch (53:7): [True: 3.83k, False: 0]
  ------------------
   54|  3.83k|    try {
   55|  3.83k|      arch->load();
   56|       |
   57|       |      // List files
   58|  3.83k|      Ogre::StringVectorPtr files = arch->list();
   59|       |
   60|       |      // Try to open first few files
   61|  3.83k|      int count = 0;
   62|  3.83k|      for (auto &f : *files) {
  ------------------
  |  Branch (62:20): [True: 3.38k, False: 3.83k]
  ------------------
   63|  3.38k|        if (count++ > 10) break;
  ------------------
  |  Branch (63:13): [True: 0, False: 3.38k]
  ------------------
   64|  3.38k|        try {
   65|  3.38k|          Ogre::DataStreamPtr stream = arch->open(f);
   66|  3.38k|          if (stream) {
  ------------------
  |  Branch (66:15): [True: 369, False: 3.01k]
  ------------------
   67|       |            // Read some data
   68|    369|            char buf[1024];
   69|    369|            stream->read(buf, std::min((size_t)1024, (size_t)stream->size()));
   70|    369|          }
   71|  3.38k|        } catch (...) {}
   72|  3.38k|      }
   73|       |
   74|  3.83k|      arch->unload();
   75|  3.83k|    } catch (...) {}
   76|  3.83k|    g_zipFactory->destroyInstance(arch);
   77|  3.83k|  }
   78|       |
   79|  3.83k|  return 0;
   80|  3.83k|}
zip_fuzz.cpp:_ZL11global_initv:
   26|  3.83k|static void global_init() {
   27|  3.83k|  if (g_initialized)
  ------------------
  |  Branch (27:7): [True: 3.83k, False: 1]
  ------------------
   28|  3.83k|    return;
   29|       |
   30|      1|  auto *logMgr = new Ogre::LogManager();
   31|      1|  logMgr->createLog("fuzz_zip.log", true, false, true);
   32|      1|  logMgr->setMinLogLevel(Ogre::LML_CRITICAL);
   33|       |
   34|      1|  new Ogre::ResourceGroupManager();
   35|      1|  new Ogre::ArchiveManager();
   36|       |
   37|      1|  g_zipFactory = new Ogre::EmbeddedZipArchiveFactory();
   38|      1|  Ogre::ArchiveManager::getSingleton().addArchiveFactory(g_zipFactory);
   39|       |
   40|      1|  g_initialized = true;
   41|      1|}

