mirror of
https://github.com/amadvance/snapraid.git
synced 2026-12-01 04:17:02 -05:00
Abort saving content file if rehash blocks exist with undefined previous checksum
This commit is contained in:
parent
a144fdc721
commit
1093ba9bbb
1 changed files with 7 additions and 0 deletions
|
|
@ -3909,6 +3909,13 @@ static void state_write_content(struct snapraid_state* state, uint32_t* out_crc)
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
|
if (info_has_rehash && state->prevhash == HASH_UNDEFINED) {
|
||||||
|
/* LCOV_EXCL_START */
|
||||||
|
log_fatal(EINTERNAL, "Internal inconsistency: Rehash blocks found but previous checksum is missing!\n");
|
||||||
|
os_abort();
|
||||||
|
/* LCOV_EXCL_STOP */
|
||||||
|
}
|
||||||
|
|
||||||
/* map disks */
|
/* map disks */
|
||||||
mapping_idx = 0;
|
mapping_idx = 0;
|
||||||
for (i = state->maplist; i != 0; i = i->next) {
|
for (i = state->maplist; i != 0; i = i->next) {
|
||||||
|
|
|
||||||
Loading…
Add table
Add a link
Reference in a new issue