IncrementalScan: Use md_array_active() instead of md_get_array_info()

This eliminates yet another case where GET_ARRAY_INFO was used to
indicate whether the array was active.

Signed-off-by: Jes Sorensen <jsorensen@fb.com>
This commit is contained in:
Jes Sorensen 2017-05-05 12:18:29 -04:00
parent 74d293a253
commit 00e56fd953
1 changed files with 1 additions and 2 deletions

View File

@ -1317,7 +1317,6 @@ int IncrementalScan(struct context *c, char *devnm)
restart:
for (me = mapl ; me ; me = me->next) {
mdu_array_info_t array;
struct mdinfo *sra;
int mdfd;
@ -1362,7 +1361,7 @@ restart:
rv = 1;
continue;
}
if (md_get_array_info(mdfd, &array) == 0 || errno != ENODEV) {
if (md_array_active(mdfd)) {
close(mdfd);
continue;
}