mirror of
https://github.com/amadvance/snapraid.git
synced 2026-11-22 16:06:30 -05:00
Extend --force-device to ignore more erroneous conditions
We want to allow fix also if some disk is unaccessible, and content files not present.
This commit is contained in:
parent
841e6306e3
commit
3e83b15bbb
12 changed files with 223 additions and 83 deletions
|
|
@ -1927,6 +1927,12 @@ int state_check(struct snapraid_state* state, int fix, block_off_t blockstart, b
|
|||
/* if fixing, create the file and open for writing */
|
||||
/* if it fails, we cannot continue */
|
||||
for (l = 0; l < state->level; ++l) {
|
||||
/* skip parity disks that are not accessible */
|
||||
if (state->parity[l].skip_access) {
|
||||
parity_ptr[l] = 0;
|
||||
continue;
|
||||
}
|
||||
|
||||
parity_ptr[l] = &parity[l];
|
||||
ret = parity_create(parity_ptr[l], state->parity[l].path, &out_size, state->file_mode);
|
||||
if (ret == -1) {
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue