mirror of
https://github.com/amadvance/snapraid.git
synced 2026-10-26 19:01:57 -04:00
Fix check for division by 0
This commit is contained in:
parent
b609df78b5
commit
ec7c4de3c9
1 changed files with 1 additions and 1 deletions
|
|
@ -4564,7 +4564,7 @@ int state_progress(struct snapraid_state* state, struct snapraid_io* io, block_o
|
|||
out_size_speed = (unsigned)(delta_size / MEGA / delta_time);
|
||||
|
||||
/* estimate the speed in block/s */
|
||||
if (delta_pos != 0)
|
||||
if (delta_time != 0)
|
||||
out_block_speed = (unsigned)(delta_pos / delta_time);
|
||||
|
||||
/* estimate the cpu usage percentage */
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue