Rizin
unix-like reverse engineering framework and cli tools
|
Compress in multi-call mode using x86 BCJ and LZMA2. More...
#include <stdbool.h>
#include <stdlib.h>
#include <stdio.h>
#include <string.h>
#include <errno.h>
#include <lzma.h>
Go to the source code of this file.
Functions | |
static bool | init_encoder (lzma_stream *strm) |
static bool | compress (lzma_stream *strm, FILE *infile, FILE *outfile) |
int | main (void) |
Compress in multi-call mode using x86 BCJ and LZMA2.
Usage: ./03_compress_custom < INFILE > OUTFILE
Example: ./03_compress_custom < foo > foo.xz
Definition in file 03_compress_custom.c.
|
static |
Definition at line 105 of file 03_compress_custom.c.
References test-lz4-speed::action, lzma_stream::avail_in, lzma_stream::avail_out, if(), inbuf, LZMA_DATA_ERROR, LZMA_FINISH, LZMA_MEM_ERROR, LZMA_OK, LZMA_RUN, LZMA_STREAM_END, msg, lzma_stream::next_in, lzma_stream::next_out, NULL, outbuf, outfile, and strm.
Referenced by main().
|
static |
Definition at line 26 of file 03_compress_custom.c.
References filters, lzma_filter::id, LZMA_CHECK_CRC64, LZMA_FILTER_LZMA2, LZMA_FILTER_X86, LZMA_MEM_ERROR, LZMA_OK, LZMA_OPTIONS_ERROR, LZMA_PRESET_DEFAULT, LZMA_UNSUPPORTED_CHECK, LZMA_VLI_UNKNOWN, msg, NULL, and strm.
Referenced by main().
int main | ( | void | ) |
Definition at line 177 of file 03_compress_custom.c.
References compress(), init_encoder(), LZMA_STREAM_INIT, and strm.