From 2e128ca83561011a9d4d14e0cde9cfe5cf428148 Mon Sep 17 00:00:00 2001 From: Pawel Jakub Dawidek Date: Thu, 30 Mar 2006 12:15:41 +0000 Subject: [PATCH] - 'ndisks' variable is not boolean, so compare it with a value. - Keep conditions order consistent with the comment above. MFC after: 3 days --- sys/geom/mirror/g_mirror.c | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/sys/geom/mirror/g_mirror.c b/sys/geom/mirror/g_mirror.c index 574fee1bfaf2..e69af5a58dc2 100644 --- a/sys/geom/mirror/g_mirror.c +++ b/sys/geom/mirror/g_mirror.c @@ -2116,7 +2116,7 @@ g_mirror_update_device(struct g_mirror_softc *sc, boolean_t force) * if we have any disks and 'force' is true. */ ndisks = g_mirror_ndisks(sc, -1); - if ((force && ndisks) || sc->sc_ndisks == ndisks) { + if (sc->sc_ndisks == ndisks || (force && ndisks > 0)) { ; } else if (ndisks == 0) { /*