summaryrefslogtreecommitdiff
path: root/Grow.c
diff options
context:
space:
mode:
Diffstat (limited to 'Grow.c')
-rw-r--r--Grow.c8
1 files changed, 5 insertions, 3 deletions
diff --git a/Grow.c b/Grow.c
index 30c5fa91..363b209d 100644
--- a/Grow.c
+++ b/Grow.c
@@ -754,7 +754,8 @@ static int check_idle(struct supertype *st)
for (e = ent ; e; e = e->next) {
if (!is_container_member(e, container))
continue;
- if (e->percent >= 0) {
+ /* frozen array is not idle*/
+ if (e->percent >= 0 || e->metadata_version[9] == '-') {
is_idle = 0;
break;
}
@@ -1195,7 +1196,8 @@ unsigned long compute_backup_blocks(int nchunk, int ochunk,
/* Find GCD */
a = GCD(a, b);
/* LCM == product / GCD */
- blocks = (ochunk/512) * (nchunk/512) * odata * ndata / a;
+ blocks = (unsigned long)(ochunk/512) * (unsigned long)(nchunk/512) *
+ odata * ndata / a;
return blocks;
}
@@ -3284,7 +3286,7 @@ static int reshape_array(char *container, int fd, char *devname,
goto release;
} else if (verbose >= 0)
printf("chunk size for %s set to %d\n",
- devname, array.chunk_size);
+ devname, info->new_chunk);
}
unfreeze(st);
return 0;