stat_line_valid(): use the FOR_EACH_STAT_ITEM macro
[paraslash.git] / stat.c
diff --git a/stat.c b/stat.c
index 4259956f6ed5724d5afac014c170a1426b2e56db..536807dc483f7353566ec1853ba8696598e517e7 100644 (file)
--- a/stat.c
+++ b/stat.c
@@ -195,7 +195,6 @@ void dump_empty_status(void)
                free(empty_items);
                empty_items = tmp;
        }
-//     PARA_DEBUG_LOG("%s: empty items: %s\n", __func__, empty_items);
        stat_client_write(empty_items);
        free(empty_items);
 }
@@ -217,7 +216,7 @@ int stat_line_valid(const char *line)
        if (!line || !*line)
                return -E_UNKNOWN_STAT_ITEM;
        line_len = strlen(line);
-       for (i = 0; i < NUM_STAT_ITEMS; i++) {
+       FOR_EACH_STAT_ITEM(i) {
                const char *s = status_item_list[i];
                size_t item_len = strlen(s);