|
Rizin
unix-like reverse engineering framework and cli tools
|
#include "platform.h"#include "util.h"#include <stdio.h>#include <stdlib.h>#include <string.h>#include <time.h>#include <sys/types.h>#include <sys/stat.h>#include "lz4.h"#include "lz4hc.h"#include "lz4frame.h"#include "lz4io.h"Go to the source code of this file.
Classes | |
| struct | LZ4IO_prefs_s |
| struct | cRess_t |
| struct | dRess_t |
| struct | LZ4IO_frameInfo_t |
| struct | LZ4IO_cFileInfo_t |
Macros | |
| #define | LZ4F_STATIC_LINKING_ONLY |
| #define | KB *(1 <<10) |
| #define | MB *(1 <<20) |
| #define | GB *(1U<<30) |
| #define | _1BIT 0x01 |
| #define | _2BITS 0x03 |
| #define | _3BITS 0x07 |
| #define | _4BITS 0x0F |
| #define | _8BITS 0xFF |
| #define | MAGICNUMBER_SIZE 4 |
| #define | LZ4IO_MAGICNUMBER 0x184D2204 |
| #define | LZ4IO_SKIPPABLE0 0x184D2A50 |
| #define | LZ4IO_SKIPPABLEMASK 0xFFFFFFF0 |
| #define | LEGACY_MAGICNUMBER 0x184C2102 |
| #define | CACHELINE 64 |
| #define | LEGACY_BLOCKSIZE (8 MB) |
| #define | MIN_STREAM_BUFSIZE (192 KB) |
| #define | LZ4IO_BLOCKSIZEID_DEFAULT 7 |
| #define | LZ4_MAX_DICT_SIZE (64 KB) |
| #define | DISPLAY(...) fprintf(stderr, __VA_ARGS__) |
| #define | DISPLAYOUT(...) fprintf(stdout, __VA_ARGS__) |
| #define | DISPLAYLEVEL(l, ...) if (g_displayLevel>=l) { DISPLAY(__VA_ARGS__); } |
| #define | DISPLAYUPDATE(l, ...) |
| #define | LZ4IO_STATIC_ASSERT(c) { enum { LZ4IO_static_assert = 1/(int)(!!(c)) }; } /* use after variable declarations */ |
| #define | DEBUG 0 |
| #define | DEBUGOUTPUT(...) if (DEBUG) DISPLAY(__VA_ARGS__); |
| #define | EXM_THROW(error, ...) |
| #define | EXTENDED_ARGUMENTS |
| #define | EXTENDED_HELP |
| #define | EXTENDED_FORMAT |
| #define | DEFAULT_DECOMPRESSOR LZ4IO_decompressLZ4F |
| #define | FNSPACE 30 |
| #define | PTSIZE (64 KB) |
| #define | PTSIZET (PTSIZE / sizeof(size_t)) |
| #define | ENDOFSTREAM ((unsigned long long)-1) |
| #define | LZ4IO_INIT_FRAMEINFO { LZ4F_INIT_FRAMEINFO, lz4Frame } |
| #define | LZ4IO_INIT_CFILEINFO { NULL, 0ULL, 0, LZ4IO_INIT_FRAMEINFO, 1, 1, 1 } |
Enumerations | |
| enum | LZ4IO_frameType_t { lz4Frame = 0 , legacyFrame , skippableFrame } |
| enum | LZ4IO_infoResult { LZ4IO_LZ4F_OK , LZ4IO_format_not_known , LZ4IO_not_a_file } |
Variables | |
| static int | g_displayLevel = 0 |
| static const clock_t | refreshRate = CLOCKS_PER_SEC / 6 |
| static clock_t | g_time = 0 |
| static unsigned | g_magicRead = 0 |
| static const size_t | LZ4IO_dBufferSize = 64 KB |
| static const char * | LZ4IO_frameTypeNames [] = {"LZ4Frame", "LegacyFrame", "SkippableFrame" } |
| #define DEFAULT_DECOMPRESSOR LZ4IO_decompressLZ4F |
| #define DISPLAYLEVEL | ( | l, | |
| ... | |||
| ) | if (g_displayLevel>=l) { DISPLAY(__VA_ARGS__); } |
| #define DISPLAYUPDATE | ( | l, | |
| ... | |||
| ) |
| #define EXM_THROW | ( | error, | |
| ... | |||
| ) |
| #define LZ4IO_INIT_CFILEINFO { NULL, 0ULL, 0, LZ4IO_INIT_FRAMEINFO, 1, 1, 1 } |
| #define LZ4IO_INIT_FRAMEINFO { LZ4F_INIT_FRAMEINFO, lz4Frame } |
| enum LZ4IO_frameType_t |
| enum LZ4IO_infoResult |
Safely handle cases when (unsigned)offset > LONG_MAX
Definition at line 1141 of file lz4io.c.
References s, SEEK_CUR, and UTIL_fseek.
Referenced by LZ4IO_getCompressedFileInfo(), and selectDecoder().
Definition at line 1486 of file lz4io.c.
References b.
Referenced by LZ4IO_displayCompressedFilesInfo().
| const char* LZ4IO_blockTypeID | ( | LZ4F_blockSizeID_t | sizeID, |
| LZ4F_blockMode_t | blockMode, | ||
| char | buffer[4] | ||
| ) |
Definition at line 1465 of file lz4io.c.
References assert(), and LZ4F_blockIndependent.
Referenced by LZ4IO_displayCompressedFilesInfo(), and LZ4IO_getCompressedFileInfo().
| int LZ4IO_compressFilename | ( | const char * | srcFileName, |
| const char * | dstFileName, | ||
| int | compressionLevel, | ||
| const LZ4IO_prefs_t * | prefs | ||
| ) |
Definition at line 774 of file lz4io.c.
References compressionLevel, DISPLAYLEVEL, LZ4IO_compressFilename_extRess(), LZ4IO_createCResources(), LZ4IO_freeCResources(), UTIL_clockSpanNano(), and UTIL_getTime().
|
static |
Definition at line 650 of file lz4io.c.
References LZ4F_preferences_t::autoFlush, LZ4IO_prefs_s::blockChecksum, LZ4F_frameInfo_t::blockChecksumFlag, LZ4IO_prefs_s::blockIndependence, LZ4F_frameInfo_t::blockMode, LZ4IO_prefs_s::blockSize, LZ4F_frameInfo_t::blockSizeID, LZ4IO_prefs_s::blockSizeId, cRess_t::cdict, LZ4F_preferences_t::compressionLevel, compressionLevel, LZ4F_frameInfo_t::contentChecksumFlag, LZ4F_frameInfo_t::contentSize, LZ4IO_prefs_s::contentSizeFlag, cRess_t::ctx, DISPLAYLEVEL, DISPLAYUPDATE, cRess_t::dstBuffer, cRess_t::dstBufferSize, EXM_THROW, LZ4F_preferences_t::favorDecSpeed, LZ4IO_prefs_s::favorDecSpeed, benchmark::FILE, LZ4F_preferences_t::frameInfo, LZ4F_compressBegin_usingCDict(), LZ4F_compressEnd(), LZ4F_compressFrame_usingCDict(), LZ4F_compressUpdate(), LZ4F_getErrorName(), LZ4F_isError(), LZ4IO_openDstFile(), LZ4IO_openSrcFile(), memset(), NULL, nulmark, LZ4IO_prefs_s::removeSrcFile, cRess_t::srcBuffer, stdinmark, stdoutmark, LZ4IO_prefs_s::streamChecksum, UTIL_getFileStat(), UTIL_getOpenFileSize(), and UTIL_setFileStat().
Referenced by LZ4IO_compressFilename(), and LZ4IO_compressMultipleFilenames().
| int LZ4IO_compressFilename_Legacy | ( | const char * | input_filename, |
| const char * | output_filename, | ||
| int | compressionlevel, | ||
| const LZ4IO_prefs_t * | prefs | ||
| ) |
Definition at line 399 of file lz4io.c.
References assert(), DISPLAYLEVEL, DISPLAYUPDATE, dst, EXM_THROW, benchmark::FILE, free(), int, LEGACY_BLOCKSIZE, LEGACY_MAGICNUMBER, long, LZ4_compress_HC(), LZ4_compressBound(), LZ4IO_LZ4_compress(), LZ4IO_openDstFile(), LZ4IO_openSrcFile(), LZ4IO_writeLE32(), MAGICNUMBER_SIZE, malloc(), NULL, src, srcSize, and stdoutmark.
Referenced by LZ4IO_compressMultipleFilenames_Legacy(), and main().
| int LZ4IO_compressMultipleFilenames | ( | const char ** | inFileNamesTable, |
| int | ifntSize, | ||
| const char * | suffix, | ||
| int | compressionLevel, | ||
| const LZ4IO_prefs_t * | prefs | ||
| ) |
Definition at line 798 of file lz4io.c.
References compressionLevel, FNSPACE, free(), i, LZ4IO_compressFilename_extRess(), LZ4IO_createCResources(), LZ4IO_freeCResources(), malloc(), NULL, stdoutmark, and suffix.
Referenced by main().
| int LZ4IO_compressMultipleFilenames_Legacy | ( | const char ** | inFileNamesTable, |
| int | ifntSize, | ||
| const char * | suffix, | ||
| int | compressionLevel, | ||
| const LZ4IO_prefs_t * | prefs | ||
| ) |
Definition at line 485 of file lz4io.c.
References compressionLevel, FNSPACE, free(), i, LZ4IO_compressFilename_Legacy(), malloc(), NULL, stdoutmark, and suffix.
Referenced by main().
|
static |
Definition at line 599 of file lz4io.c.
References LZ4IO_prefs_s::dictionaryFilename, EXM_THROW, free(), LZ4F_createCDict(), LZ4IO_createDict(), NULL, and LZ4IO_prefs_s::useDictionary.
Referenced by LZ4IO_createCResources().
|
static |
Definition at line 612 of file lz4io.c.
References LZ4IO_prefs_s::blockSize, cRess_t::cdict, cRess_t::ctx, cRess_t::dstBuffer, cRess_t::dstBufferSize, EXM_THROW, LZ4F_compressFrameBound(), LZ4F_createCompressionContext(), LZ4F_getErrorName(), LZ4F_isError(), LZ4F_VERSION, LZ4IO_createCDict(), malloc(), NULL, cRess_t::srcBuffer, and cRess_t::srcBufferSize.
Referenced by LZ4IO_compressFilename(), and LZ4IO_compressMultipleFilenames().
Definition at line 543 of file lz4io.c.
References EXM_THROW, benchmark::FILE, free(), LZ4_MAX_DICT_SIZE, LZ4IO_openSrcFile(), malloc(), memcpy(), NULL, SEEK_END, stdinmark, and UTIL_fseek.
Referenced by LZ4IO_createCDict(), and LZ4IO_loadDDict().
|
static |
Definition at line 1020 of file lz4io.c.
References dRess_t::dCtx, dRess_t::dstBuffer, dRess_t::dstBufferSize, dRess_t::dstFile, EXM_THROW, LZ4F_createDecompressionContext(), LZ4F_getErrorName(), LZ4F_isError(), LZ4F_VERSION, LZ4IO_dBufferSize, LZ4IO_loadDDict(), malloc(), NULL, dRess_t::srcBuffer, and dRess_t::srcBufferSize.
Referenced by LZ4IO_decompressFilename(), and LZ4IO_decompressMultipleFilenames().
|
static |
Definition at line 947 of file lz4io.c.
References EXM_THROW, free(), g_magicRead, LEGACY_BLOCKSIZE, long, LZ4_compressBound(), LZ4_COMPRESSBOUND, LZ4_decompress_safe(), LZ4IO_fwriteSparse(), LZ4IO_fwriteSparseEnd(), LZ4IO_readLE32(), malloc(), and LZ4IO_prefs_s::sparseFileSupport.
Referenced by selectDecoder().
|
static |
Definition at line 1262 of file lz4io.c.
References dRess_t::dstFile, benchmark::FILE, LZ4IO_decompressSrcFile(), LZ4IO_openDstFile(), NULL, nulmark, stdinmark, stdoutmark, UTIL_getFileStat(), and UTIL_setFileStat().
Referenced by LZ4IO_decompressFilename(), and LZ4IO_decompressMultipleFilenames().
| int LZ4IO_decompressFilename | ( | const char * | input_filename, |
| const char * | output_filename, | ||
| const LZ4IO_prefs_t * | prefs | ||
| ) |
Definition at line 1292 of file lz4io.c.
References DISPLAYLEVEL, test_evm::end, LZ4IO_createDResources(), LZ4IO_decompressDstFile(), LZ4IO_freeDResources(), and start.
|
static |
Definition at line 1052 of file lz4io.c.
References dRess_t::dCtx, dRess_t::dictBuffer, dRess_t::dictBufferSize, DISPLAYUPDATE, dRess_t::dstBuffer, dRess_t::dstBufferSize, EXM_THROW, LZ4F_decompress_usingDict(), LZ4F_getErrorName(), LZ4F_isError(), LZ4IO_fwriteSparse(), LZ4IO_fwriteSparseEnd(), LZ4IO_MAGICNUMBER, LZ4IO_writeLE32(), MAGICNUMBER_SIZE, NULL, pos, LZ4IO_prefs_s::sparseFileSupport, dRess_t::srcBuffer, dRess_t::srcBufferSize, and LZ4IO_prefs_s::testMode.
Referenced by selectDecoder().
| int LZ4IO_decompressMultipleFilenames | ( | const char ** | inFileNamesTable, |
| int | ifntSize, | ||
| const char * | suffix, | ||
| const LZ4IO_prefs_t * | prefs | ||
| ) |
Definition at line 1308 of file lz4io.c.
References DISPLAYLEVEL, dRess_t::dstFile, EXM_THROW, FNSPACE, free(), i, LZ4IO_createDResources(), LZ4IO_decompressDstFile(), LZ4IO_decompressSrcFile(), LZ4IO_freeDResources(), LZ4IO_openDstFile(), malloc(), memcpy(), NULL, stdoutmark, and suffix.
Referenced by main().
|
static |
Definition at line 1225 of file lz4io.c.
References assert(), DISPLAYLEVEL, dRess_t::dstFile, ENDOFSTREAM, EXM_THROW, benchmark::FILE, LZ4IO_openSrcFile(), NULL, LZ4IO_prefs_s::removeSrcFile, and selectDecoder().
Referenced by LZ4IO_decompressDstFile(), and LZ4IO_decompressMultipleFilenames().
| LZ4IO_prefs_t* LZ4IO_defaultPreferences | ( | void | ) |
Definition at line 160 of file lz4io.c.
References LZ4IO_prefs_s::blockChecksum, LZ4IO_prefs_s::blockIndependence, LZ4IO_prefs_s::blockSize, LZ4IO_prefs_s::blockSizeId, LZ4IO_prefs_s::contentSizeFlag, LZ4IO_prefs_s::dictionaryFilename, EXM_THROW, LZ4IO_prefs_s::favorDecSpeed, LZ4IO_BLOCKSIZEID_DEFAULT, malloc(), NULL, LZ4IO_prefs_s::overwrite, LZ4IO_prefs_s::passThrough, LZ4IO_prefs_s::removeSrcFile, LZ4IO_prefs_s::sparseFileSupport, LZ4IO_prefs_s::streamChecksum, LZ4IO_prefs_s::testMode, and LZ4IO_prefs_s::useDictionary.
Referenced by main().
Definition at line 1630 of file lz4io.c.
References LZ4IO_cFileInfo_t::allContentSize, assert(), LZ4F_frameInfo_t::blockMode, LZ4F_frameInfo_t::blockSizeID, LZ4F_frameInfo_t::contentSize, DISPLAYLEVEL, DISPLAYOUT, LZ4IO_cFileInfo_t::eqBlockTypes, LZ4IO_cFileInfo_t::eqFrameTypes, LZ4IO_cFileInfo_t::fileName, LZ4IO_cFileInfo_t::fileSize, LZ4IO_cFileInfo_t::frameCount, LZ4IO_cFileInfo_t::frameSummary, LZ4IO_frameInfo_t::frameType, g_displayLevel, setup::idx, LZ4IO_frameInfo_t::lz4FrameInfo, LZ4IO_baseName(), LZ4IO_blockTypeID(), LZ4IO_format_not_known, LZ4IO_frameTypeNames, LZ4IO_getCompressedFileInfo(), LZ4IO_INIT_CFILEINFO, LZ4IO_LZ4F_OK, LZ4IO_toHuman(), and UTIL_isRegFile().
Referenced by main().
| void LZ4IO_favorDecSpeed | ( | LZ4IO_prefs_t *const | prefs, |
| int | favor | ||
| ) |
Definition at line 288 of file lz4io.c.
References LZ4IO_prefs_s::favorDecSpeed.
Referenced by main().
|
static |
Definition at line 632 of file lz4io.c.
References cRess_t::cdict, cRess_t::ctx, cRess_t::dstBuffer, EXM_THROW, free(), LZ4F_freeCDict(), LZ4F_freeCompressionContext(), LZ4F_getErrorName(), LZ4F_isError(), NULL, and cRess_t::srcBuffer.
Referenced by LZ4IO_compressFilename(), and LZ4IO_compressMultipleFilenames().
|
static |
Definition at line 1041 of file lz4io.c.
References dRess_t::dCtx, dRess_t::dictBuffer, dRess_t::dstBuffer, EXM_THROW, free(), LZ4F_freeDecompressionContext(), LZ4F_getErrorName(), LZ4F_isError(), and dRess_t::srcBuffer.
Referenced by LZ4IO_decompressFilename(), and LZ4IO_decompressMultipleFilenames().
| void LZ4IO_freePreferences | ( | LZ4IO_prefs_t * | prefs | ) |
|
static |
Definition at line 864 of file lz4io.c.
References EXM_THROW, GB, KB, SEEK_CUR, unsigned, and UTIL_fseek.
Referenced by LZ4IO_decodeLegacyStream(), LZ4IO_decompressLZ4F(), and LZ4IO_passThrough().
|
static |
Definition at line 934 of file lz4io.c.
References EXM_THROW, SEEK_CUR, and UTIL_fseek.
Referenced by LZ4IO_decodeLegacyStream(), LZ4IO_decompressLZ4F(), and LZ4IO_passThrough().
|
static |
Definition at line 1500 of file lz4io.c.
References LZ4IO_cFileInfo_t::allContentSize, LZ4F_frameInfo_t::blockChecksumFlag, LZ4F_frameInfo_t::blockMode, LZ4F_frameInfo_t::blockSizeID, LZ4F_frameInfo_t::contentChecksumFlag, LZ4F_frameInfo_t::contentSize, DISPLAYLEVEL, LZ4IO_cFileInfo_t::eqBlockTypes, LZ4IO_cFileInfo_t::eqFrameTypes, EXM_THROW, benchmark::FILE, LZ4IO_cFileInfo_t::fileSize, LZ4IO_cFileInfo_t::frameCount, LZ4IO_cFileInfo_t::frameSummary, LZ4IO_frameInfo_t::frameType, fseek_u32(), LEGACY_MAGICNUMBER, legacyFrame, LZ4F_createDecompressionContext(), LZ4F_freeDecompressionContext(), LZ4F_getFrameInfo(), LZ4F_HEADER_SIZE_MAX, LZ4F_HEADER_SIZE_MIN, LZ4F_headerSize(), LZ4F_isError(), LZ4F_VERSION, lz4Frame, LZ4IO_frameInfo_t::lz4FrameInfo, LZ4IO_blockTypeID(), LZ4IO_format_not_known, LZ4IO_frameTypeNames, LZ4IO_INIT_FRAMEINFO, LZ4IO_isSkippableMagicNumber(), LZ4IO_LZ4F_OK, LZ4IO_MAGICNUMBER, LZ4IO_not_a_file, LZ4IO_openSrcFile(), LZ4IO_readLE32(), LZ4IO_skipBlocksData(), LZ4IO_skipLegacyBlocksData(), LZ4IO_SKIPPABLE0, MAGICNUMBER_SIZE, NULL, SEEK_CUR, skippableFrame, and UTIL_getOpenFileSize().
Referenced by LZ4IO_displayCompressedFilesInfo().
Definition at line 304 of file lz4io.c.
References LZ4IO_SKIPPABLE0, and LZ4IO_SKIPPABLEMASK.
Referenced by LZ4IO_getCompressedFileInfo(), LZ4IO_skipLegacyBlocksData(), and selectDecoder().
|
static |
Definition at line 1007 of file lz4io.c.
References dRess_t::dictBuffer, dRess_t::dictBufferSize, LZ4IO_prefs_s::dictionaryFilename, EXM_THROW, LZ4IO_createDict(), NULL, and LZ4IO_prefs_s::useDictionary.
Referenced by LZ4IO_createDResources().
|
static |
Definition at line 390 of file lz4io.c.
References dst, LZ4_compress_fast(), src, and srcSize.
Referenced by LZ4IO_compressFilename_Legacy().
|
static |
FIO_openDstFile() : prefs is writable, because sparseFileSupport might be updated. condition : dstFileName must be non-NULL.
dstFileName, or NULL if it fails Definition at line 332 of file lz4io.c.
References assert(), DISPLAY, DISPLAYLEVEL, f, benchmark::FILE, g_displayLevel, NULL, nulmark, LZ4IO_prefs_s::overwrite, SET_BINARY_MODE, SET_SPARSE_FILE_MODE, LZ4IO_prefs_s::sparseFileSupport, and stdoutmark.
Referenced by LZ4IO_compressFilename_extRess(), LZ4IO_compressFilename_Legacy(), LZ4IO_decompressDstFile(), and LZ4IO_decompressMultipleFilenames().
|
static |
LZ4IO_openSrcFile() : condition : srcFileName must be non-NULL.
dstFileName, or NULL if it fails Definition at line 312 of file lz4io.c.
References DISPLAYLEVEL, f, benchmark::FILE, NULL, SET_BINARY_MODE, and stdinmark.
Referenced by LZ4IO_compressFilename_extRess(), LZ4IO_compressFilename_Legacy(), LZ4IO_createDict(), LZ4IO_decompressSrcFile(), and LZ4IO_getCompressedFileInfo().
|
static |
Definition at line 1116 of file lz4io.c.
References EXM_THROW, LZ4IO_fwriteSparse(), LZ4IO_fwriteSparseEnd(), MAGICNUMBER_SIZE, and PTSIZET.
Referenced by selectDecoder().
Definition at line 852 of file lz4io.c.
Referenced by LZ4IO_decodeLegacyStream(), LZ4IO_getCompressedFileInfo(), LZ4IO_skipBlocksData(), LZ4IO_skipLegacyBlocksData(), and selectDecoder().
| int LZ4IO_setBlockChecksumMode | ( | LZ4IO_prefs_t *const | prefs, |
| int | enable | ||
| ) |
Definition at line 253 of file lz4io.c.
References LZ4IO_prefs_s::blockChecksum.
Referenced by main().
| int LZ4IO_setBlockMode | ( | LZ4IO_prefs_t *const | prefs, |
| LZ4IO_blockMode_t | blockMode | ||
| ) |
Definition at line 246 of file lz4io.c.
References LZ4IO_prefs_s::blockIndependence, and LZ4IO_blockIndependent.
Referenced by main().
| size_t LZ4IO_setBlockSize | ( | LZ4IO_prefs_t *const | prefs, |
| size_t | blockSize | ||
| ) |
Definition at line 228 of file lz4io.c.
References LZ4IO_prefs_s::blockSize, LZ4IO_prefs_s::blockSizeId, int, and MB.
Referenced by main().
| size_t LZ4IO_setBlockSizeID | ( | LZ4IO_prefs_t *const | prefs, |
| unsigned | bsid | ||
| ) |
Definition at line 217 of file lz4io.c.
References LZ4IO_prefs_s::blockSize, LZ4IO_prefs_s::blockSizeId, int, KB, MB, and unsigned.
Referenced by main().
| int LZ4IO_setContentSize | ( | LZ4IO_prefs_t *const | prefs, |
| int | enable | ||
| ) |
Definition at line 281 of file lz4io.c.
References LZ4IO_prefs_s::contentSizeFlag.
Referenced by main().
| int LZ4IO_setDictionaryFilename | ( | LZ4IO_prefs_t *const | prefs, |
| const char * | dictionaryFilename | ||
| ) |
Definition at line 187 of file lz4io.c.
References LZ4IO_prefs_s::dictionaryFilename, NULL, and LZ4IO_prefs_s::useDictionary.
Referenced by main().
| int LZ4IO_setOverwrite | ( | LZ4IO_prefs_t *const | prefs, |
| int | yes | ||
| ) |
| int LZ4IO_setPassThrough | ( | LZ4IO_prefs_t *const | prefs, |
| int | yes | ||
| ) |
Definition at line 195 of file lz4io.c.
References LZ4IO_prefs_s::passThrough.
Referenced by main().
| void LZ4IO_setRemoveSrcFile | ( | LZ4IO_prefs_t *const | prefs, |
| unsigned | flag | ||
| ) |
Definition at line 293 of file lz4io.c.
References LZ4IO_prefs_s::removeSrcFile.
Referenced by main().
| int LZ4IO_setSparseFile | ( | LZ4IO_prefs_t *const | prefs, |
| int | enable | ||
| ) |
Definition at line 274 of file lz4io.c.
References LZ4IO_prefs_s::sparseFileSupport.
Referenced by main().
| int LZ4IO_setStreamChecksumMode | ( | LZ4IO_prefs_t *const | prefs, |
| int | enable | ||
| ) |
Definition at line 260 of file lz4io.c.
References LZ4IO_prefs_s::streamChecksum.
Referenced by main().
| int LZ4IO_setTestMode | ( | LZ4IO_prefs_t *const | prefs, |
| int | yes | ||
| ) |
|
static |
Definition at line 1394 of file lz4io.c.
References assert(), LZ4F_BLOCK_CHECKSUM_SIZE, LZ4F_BLOCK_HEADER_SIZE, LZ4F_CONTENT_CHECKSUM_SIZE, LZ4IO_readLE32(), SEEK_CUR, and UTIL_fseek.
Referenced by LZ4IO_getCompressedFileInfo().
Definition at line 1434 of file lz4io.c.
References LEGACY_MAGICNUMBER, LZ4IO_isSkippableMagicNumber(), LZ4IO_MAGICNUMBER, LZ4IO_readLE32(), LZ4IO_STATIC_ASSERT, LZIO_LEGACY_BLOCK_HEADER_SIZE, MAGICNUMBER_SIZE, SEEK_CUR, and UTIL_fseek.
Referenced by LZ4IO_getCompressedFileInfo().
|
static |
Definition at line 381 of file lz4io.c.
References p.
Referenced by LZ4IO_compressFilename_Legacy(), and LZ4IO_decompressLZ4F().
|
static |
Definition at line 1159 of file lz4io.c.
References DISPLAYLEVEL, ENDOFSTREAM, EXM_THROW, EXTENDED_FORMAT, fseek_u32(), g_magicRead, LEGACY_MAGICNUMBER, LZ4IO_decodeLegacyStream(), LZ4IO_decompressLZ4F(), LZ4IO_isSkippableMagicNumber(), LZ4IO_MAGICNUMBER, LZ4IO_passThrough(), LZ4IO_readLE32(), LZ4IO_SKIPPABLE0, MAGICNUMBER_SIZE, LZ4IO_prefs_s::overwrite, LZ4IO_prefs_s::passThrough, SEEK_CUR, LZ4IO_prefs_s::sparseFileSupport, and LZ4IO_prefs_s::testMode.
Referenced by LZ4IO_decompressSrcFile().
|
static |
Definition at line 95 of file lz4io.c.
Referenced by LZ4IO_displayCompressedFilesInfo(), LZ4IO_openDstFile(), and LZ4IO_setNotificationLevel().
|
static |
Definition at line 946 of file lz4io.c.
Referenced by LZ4IO_decodeLegacyStream(), and selectDecoder().
Definition at line 1019 of file lz4io.c.
Referenced by LZ4IO_createDResources().
|
static |
Definition at line 1385 of file lz4io.c.
Referenced by LZ4IO_displayCompressedFilesInfo(), and LZ4IO_getCompressedFileInfo().