summaryrefslogtreecommitdiff
path: root/util.c
diff options
context:
space:
mode:
authorNeilBrown <neilb@suse.de>2011-02-01 14:44:02 +1100
committerNeilBrown <neilb@suse.de>2011-02-01 14:44:02 +1100
commite5508b361d970a7657c9f81303223fa114bdcd9b (patch)
treebb4e33ec35abc0938bc8f9e2cb69ab5aee7c1cb7 /util.c
parentd11128690b61e61c1ff12b2c4b3d7028a0715b1d (diff)
Allow domain_test to report that no domains were found.
Sometime we will need to know the difference between no domains found and domains didn't match. So allow domain_test to return different values and fix up all callers to maintain current behaviour. Signed-off-by: NeilBrown <neilb@suse.de>
Diffstat (limited to 'util.c')
-rw-r--r--util.c2
1 files changed, 1 insertions, 1 deletions
diff --git a/util.c b/util.c
index a0d8283c..81f93601 100644
--- a/util.c
+++ b/util.c
@@ -1956,7 +1956,7 @@ struct mdinfo *container_choose_spares(struct supertype *st,
if (spare_group)
pol_add(&pol, pol_domain,
spare_group, NULL);
- if (!domain_test(domlist, pol, metadata))
+ if (domain_test(domlist, pol, metadata) != 1)
found = 0;
dev_policy_free(pol);
}