cli: use IWINFO_HTMODE_COUNT
authorAndre Heider <a.heider@gmail.com>
Mon, 21 Nov 2022 09:58:14 +0000 (10:58 +0100)
committerJo-Philipp Wich <jo@mein.io>
Thu, 15 Dec 2022 23:09:07 +0000 (00:09 +0100)
ARRAY_SIZE works too, but just the sake of consistency.

Signed-off-by: Andre Heider <a.heider@gmail.com>
iwinfo_cli.c

index b43c52e4f83efe4c905e527a04594e41306b7779..7aa990c243ed1e3bfdba86642128693b4d6324a7 100644 (file)
@@ -814,7 +814,7 @@ static void print_htmodelist(const struct iwinfo_ops *iw, const char *ifname)
                return;
        }
 
-       for (i = 0; i < ARRAY_SIZE(IWINFO_HTMODE_NAMES); i++)
+       for (i = 0; i < IWINFO_HTMODE_COUNT; i++)
                if (htmodes & (1 << i))
                        printf("%s ", IWINFO_HTMODE_NAMES[i]);