mirror of
https://github.com/amadvance/snapraid.git
synced 2026-11-28 19:06:42 -05:00
Assumes also CHG blocks with a NULL hash without needing an info block.
Some refactoring and renaming of other hash functions to avoid misunderstanding.
This commit is contained in:
parent
9ad388724e
commit
e0afd0edf7
6 changed files with 50 additions and 34 deletions
2
scrub.c
2
scrub.c
|
|
@ -266,7 +266,7 @@ static int state_scrub_process(struct snapraid_state* state, struct snapraid_par
|
|||
memhash(state->hash, state->hashseed, hash, buffer[j], read_size);
|
||||
}
|
||||
|
||||
if (block_has_hash(block)) {
|
||||
if (block_has_updated_hash(block)) {
|
||||
/* compare the hash */
|
||||
if (memcmp(hash, block->hash, HASH_SIZE) != 0) {
|
||||
fprintf(stdlog, "error:%u:%s:%s: Data error at position %u\n", i, handle[j].disk->name, block_file_get(block)->sub, block_file_pos(block));
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue