From e5508b361d970a7657c9f81303223fa114bdcd9b Mon Sep 17 00:00:00 2001 From: NeilBrown Date: Tue, 1 Feb 2011 14:44:02 +1100 Subject: 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 --- Assemble.c | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) (limited to 'Assemble.c') diff --git a/Assemble.c b/Assemble.c index a9c7875a..b3f54ce4 100644 --- a/Assemble.c +++ b/Assemble.c @@ -597,7 +597,7 @@ int Assemble(struct supertype *st, char *mddev, } else { struct dev_policy *pol = NULL; pol = devnum_policy(stb.st_rdev); - if (domain_test(domains, pol, NULL)) + if (domain_test(domains, pol, NULL) == 1) /* take this spare if domains match */ tmpdev->used = 1; else -- cgit v1.2.3