summaryrefslogtreecommitdiff
path: root/lib/sqfs/process_block.c
diff options
context:
space:
mode:
Diffstat (limited to 'lib/sqfs/process_block.c')
-rw-r--r--lib/sqfs/process_block.c4
1 files changed, 3 insertions, 1 deletions
diff --git a/lib/sqfs/process_block.c b/lib/sqfs/process_block.c
index f8b4d6c..3289767 100644
--- a/lib/sqfs/process_block.c
+++ b/lib/sqfs/process_block.c
@@ -26,8 +26,10 @@ int sqfs_block_process(sqfs_block_t *block, sqfs_compressor_t *cmp,
ret = cmp->do_block(cmp, block->data, block->size,
scratch, scratch_size);
- if (ret < 0)
+ if (ret < 0) {
+ block->flags |= SQFS_BLK_COMPRESS_ERROR;
return ret;
+ }
if (ret > 0) {
memcpy(block->data, scratch, ret);