const lzma_allocator lzma_vli unpadded_size
const lzma_allocator const uint8_t size_t uint8_t size_t * out_pos
const lzma_allocator * allocator
const lzma_allocator const uint8_t size_t uint8_t * out
lzma_outbuf * lzma_outq_get_buf(lzma_outq *outq)
Get a new buffer.
static bool lzma_outq_has_buf(const lzma_outq *outq)
Test if there is at least one buffer free.
void lzma_outq_end(lzma_outq *outq, const lzma_allocator *allocator)
Free the memory associated with the output queue.
bool lzma_outq_is_readable(const lzma_outq *outq)
Test if there is data ready to be read.
lzma_ret lzma_outq_read(lzma_outq *restrict outq, uint8_t *restrict out, size_t *restrict out_pos, size_t out_size, lzma_vli *restrict unpadded_size, lzma_vli *restrict uncompressed_size)
Read finished data.
uint64_t lzma_outq_memusage(uint64_t buf_size_max, uint32_t threads)
Calculate the memory usage of an output queue.
lzma_ret lzma_outq_init(lzma_outq *outq, const lzma_allocator *allocator, uint64_t buf_size_max, uint32_t threads)
Initialize an output queue.
static bool lzma_outq_is_empty(const lzma_outq *outq)
Test if the queue is completely empty.
Custom functions for memory handling.
Output buffer for a single thread.
size_t size
Amount of data written to buf.
lzma_vli uncompressed_size
uint8_t * buf
Pointer to the output buffer of lzma_outq.buf_size_max bytes.
lzma_vli unpadded_size
Additional size information.
lzma_outbuf * bufs
Array of buffers that are used cyclically.
size_t buf_size_max
Amount of buffer space available in each buffer.
uint32_t bufs_allocated
Number of buffers allocated.
size_t read_pos
Position in the buffer in lzma_outq_read()
uint32_t bufs_used
Number of buffers in use.
uint8_t * bufs_mem
Memory allocated for all the buffers.
Definitions common to the whole liblzma library.
uint64_t uncompressed_size
static uv_thread_t * threads
uint64_t lzma_vli
Variable-length integer type.
lzma_ret
Return values used by several functions in liblzma.