outqueue.c   outqueue.c 
skipping to change at line 53 skipping to change at line 53
if (get_options(&bufs_alloc_size, &bufs_count, buf_size_max, threads ) if (get_options(&bufs_alloc_size, &bufs_count, buf_size_max, threads )
!= LZMA_OK) != LZMA_OK)
return UINT64_MAX; return UINT64_MAX;
return sizeof(lzma_outq) + bufs_count * sizeof(lzma_outbuf) return sizeof(lzma_outq) + bufs_count * sizeof(lzma_outbuf)
+ bufs_alloc_size; + bufs_alloc_size;
} }
extern lzma_ret extern lzma_ret
lzma_outq_init(lzma_outq *outq, lzma_allocator *allocator, lzma_outq_init(lzma_outq *outq, const lzma_allocator *allocator,
uint64_t buf_size_max, uint32_t threads) uint64_t buf_size_max, uint32_t threads)
{ {
uint64_t bufs_alloc_size; uint64_t bufs_alloc_size;
uint32_t bufs_count; uint32_t bufs_count;
// Set bufs_count and bufs_alloc_size. // Set bufs_count and bufs_alloc_size.
return_if_error(get_options(&bufs_alloc_size, &bufs_count, return_if_error(get_options(&bufs_alloc_size, &bufs_count,
buf_size_max, threads)); buf_size_max, threads));
// Allocate memory if needed. // Allocate memory if needed.
skipping to change at line 96 skipping to change at line 96
outq->buf_size_max = (size_t)(buf_size_max); outq->buf_size_max = (size_t)(buf_size_max);
outq->bufs_allocated = bufs_count; outq->bufs_allocated = bufs_count;
outq->bufs_pos = 0; outq->bufs_pos = 0;
outq->bufs_used = 0; outq->bufs_used = 0;
outq->read_pos = 0; outq->read_pos = 0;
return LZMA_OK; return LZMA_OK;
} }
extern void extern void
lzma_outq_end(lzma_outq *outq, lzma_allocator *allocator) lzma_outq_end(lzma_outq *outq, const lzma_allocator *allocator)
{ {
lzma_free(outq->bufs, allocator); lzma_free(outq->bufs, allocator);
outq->bufs = NULL; outq->bufs = NULL;
lzma_free(outq->bufs_mem, allocator); lzma_free(outq->bufs_mem, allocator);
outq->bufs_mem = NULL; outq->bufs_mem = NULL;
return; return;
} }
 End of changes. 2 change blocks. 
2 lines changed or deleted 2 lines changed or added

This html diff was produced by rfcdiff 1.41. The latest version is available from http://tools.ietf.org/tools/rfcdiff/