]> git.ipfire.org Git - thirdparty/systemd.git/commitdiff
basic/string-table: inline the iterator declaration
authorZbigniew Jędrzejewski-Szmek <zbyszek@in.waw.pl>
Sat, 13 Feb 2021 15:08:04 +0000 (16:08 +0100)
committerZbigniew Jędrzejewski-Szmek <zbyszek@in.waw.pl>
Sun, 14 Feb 2021 10:24:45 +0000 (11:24 +0100)
src/basic/string-table.h

index aca6a267bd1ae0bd198e3b2d3a81eaa19a2424f3..97c1adc07d94df44949e58460d6e7cf141ca2299 100644 (file)
@@ -103,9 +103,8 @@ ssize_t string_table_lookup(const char * const *table, size_t len, const char *k
 
 #define DUMP_STRING_TABLE(name,type,max)                                \
         do {                                                            \
-                type _k;                                                \
                 flockfile(stdout);                                      \
-                for (_k = 0; _k < (max); _k++) {                        \
+                for (type _k = 0; _k < (max); _k++) {                   \
                         const char *_t;                                 \
                         _t = name##_to_string(_k);                      \
                         if (!_t)                                        \