Fix regression when using 'grow' to add a bitmap.

When we allowed a devlist to accompany some --grow modes - but not
--bitmap - we made --bitmap always fail, in stead of fail of a device
was given to add.
As 'devs_found' includes the md device, we need to  compare against
'1'.

Signed-off-by: NeilBrown <neilb@suse.de>
This commit is contained in:
NeilBrown 2011-03-15 16:31:20 +11:00
parent 88b496c269
commit 1d8862cf61
1 changed files with 1 additions and 1 deletions

View File

@ -1646,7 +1646,7 @@ int main(int argc, char *argv[])
}
} else if (bitmap_file) {
if (size >= 0 || raiddisks || chunk ||
layout_str != NULL || devs_found) {
layout_str != NULL || devs_found > 1) {
fprintf(stderr, Name ": --bitmap changes cannot be "
"used with other geometry changes "
"in --grow mode\n");