mirror of
https://github.com/amadvance/snapraid.git
synced 2026-11-20 06:56:28 -05:00
Return with an error code if the there is a thermal alert that prevent starting
This commit is contained in:
parent
03fb7d3cff
commit
5dfeaf0ef6
5 changed files with 65 additions and 27 deletions
|
|
@ -4576,7 +4576,7 @@ int state_progress_begin(struct snapraid_state* state, block_off_t blockstart, b
|
|||
|
||||
/* start of thermal control */
|
||||
if (!state_thermal_begin(state, now))
|
||||
return 0;
|
||||
return -1;
|
||||
|
||||
/* stop if requested */
|
||||
if (global_interrupt) {
|
||||
|
|
@ -4586,11 +4586,11 @@ int state_progress_begin(struct snapraid_state* state, block_off_t blockstart, b
|
|||
}
|
||||
log_tag("sigint:0: SIGINT received\n");
|
||||
log_flush();
|
||||
return 0;
|
||||
return 1;
|
||||
/* LCOV_EXCL_STOP */
|
||||
}
|
||||
|
||||
return 1;
|
||||
return 0;
|
||||
}
|
||||
|
||||
void state_progress_end(struct snapraid_state* state, block_off_t countpos, block_off_t countmax, data_off_t countsize, const char* msg)
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue