diff options
author | Dimitri John Ledkov <xnox@ubuntu.com> | 2018-06-26 15:38:57 +0100 |
---|---|---|
committer | Dimitri John Ledkov <xnox@ubuntu.com> | 2018-06-26 15:38:57 +0100 |
commit | 9421e599c44cd50d3df4cd019cd3c53d9320e93d (patch) | |
tree | 2d9606679ad49fbc9f9cf72b3a3a87d7a6dc8fff /Query.c | |
parent | ec9bfc63255cdf01a67171d1228f562c927c6d36 (diff) |
Cherrypick master patches up to 4th of June 2018.debian/4.1_rc1-3archive/debian/4.1_rc1-3
Diffstat (limited to 'Query.c')
-rw-r--r-- | Query.c | 5 |
1 files changed, 2 insertions, 3 deletions
@@ -85,12 +85,11 @@ int Query(char *dev) if (ioctlerr == ENODEV) printf("%s: is an md device which is not active\n", dev); + else if (ioctlerr && major(stb.st_rdev) != MD_MAJOR) + printf("%s: is not an md array\n", dev); else if (ioctlerr) printf("%s: is an md device, but gives \"%s\" when queried\n", dev, strerror(ioctlerr)); - else if (staterr) - printf("%s: is not a valid md device, returning %s\n", - dev, strerror(ioctlerr)); else { printf("%s: %s %s %d devices, %d spare%s. Use mdadm --detail for more detail.\n", dev, human_size_brief(larray_size,IEC), |