Skip to content

Commit 027c983

Browse files
committed
scan: fix flag check for corrupted chunks
Signed-off-by: Eduardo Silva <eduardo@chronosphere.io>
1 parent b472529 commit 027c983

1 file changed

Lines changed: 2 additions & 1 deletion

File tree

src/cio_scan.c

Lines changed: 2 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -106,7 +106,8 @@ static int cio_scan_stream_files(struct cio_ctx *ctx, struct cio_stream *st,
106106

107107
if (ctx->options.flags & CIO_DELETE_IRRECOVERABLE) {
108108
if (err == CIO_CORRUPTED) {
109-
if (ctx->last_chunk_error == CIO_ERR_BAD_FILE_SIZE ||
109+
if (ctx->last_chunk_error == CIO_ERR_BAD_CHECKSUM ||
110+
ctx->last_chunk_error == CIO_ERR_BAD_FILE_SIZE ||
110111
ctx->last_chunk_error == CIO_ERR_BAD_LAYOUT)
111112
{
112113
cio_log_error(ctx, "[cio scan] discarding irrecoverable chunk");

0 commit comments

Comments
 (0)