| Index: src/liblzma/common/block_encoder.c
|
| ===================================================================
|
| --- src/liblzma/common/block_encoder.c (revision 50504)
|
| +++ src/liblzma/common/block_encoder.c (working copy)
|
| @@ -144,7 +144,7 @@
|
|
|
| static lzma_ret
|
| block_encoder_update(lzma_coder *coder, lzma_allocator *allocator,
|
| - const lzma_filter *filters lzma_attribute((unused)),
|
| + const lzma_filter *filters lzma_attribute((__unused__)),
|
| const lzma_filter *reversed_filters)
|
| {
|
| if (coder->sequence != SEQ_CODE)
|
| @@ -161,6 +161,11 @@
|
| {
|
| lzma_next_coder_init(&lzma_block_encoder_init, next, allocator);
|
|
|
| + if (block == NULL)
|
| + return LZMA_PROG_ERROR;
|
| +
|
| + // The contents of the structure may depend on the version so
|
| + // check the version first.
|
| if (block->version != 0)
|
| return LZMA_OPTIONS_ERROR;
|
|
|
|
|