MCPcopy Create free account
hub / github.com/TheRealMJP/DeferredTexturing / mz_zip_file_read_func

Function mz_zip_file_read_func

SampleFramework12/v1.00/TinyEXR.cpp:4721–4730  ·  view source on GitHub ↗

Source from the content-addressed store, hash-verified

4719
4720#ifndef MINIZ_NO_STDIO
4721static size_t mz_zip_file_read_func(void *pOpaque, mz_uint64 file_ofs,
4722 void *pBuf, size_t n) {
4723 mz_zip_archive *pZip = (mz_zip_archive *)pOpaque;
4724 mz_int64 cur_ofs = MZ_FTELL64(pZip->m_pState->m_pFile);
4725 if (((mz_int64)file_ofs < 0) ||
4726 (((cur_ofs != (mz_int64)file_ofs)) &&
4727 (MZ_FSEEK64(pZip->m_pState->m_pFile, (mz_int64)file_ofs, SEEK_SET))))
4728 return 0;
4729 return MZ_FREAD(pBuf, 1, n, pZip->m_pState->m_pFile);
4730}
4731
4732mz_bool mz_zip_reader_init_file(mz_zip_archive *pZip, const char *pFilename,
4733 mz_uint32 flags) {

Callers

nothing calls this directly

Calls

no outgoing calls

Tested by

no test coverage detected