From 90e74a66e663f1776457d599cb7d5ce44785a56c Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Zbigniew=20J=C4=99drzejewski-Szmek?= Date: Tue, 8 Sep 2020 11:58:29 +0200 Subject: tree-wide: define iterator inside of the macro --- src/test/test-install-root.c | 3 +-- 1 file changed, 1 insertion(+), 2 deletions(-) (limited to 'src/test/test-install-root.c') diff --git a/src/test/test-install-root.c b/src/test/test-install-root.c index f309160889..6fb2fd4298 100644 --- a/src/test/test-install-root.c +++ b/src/test/test-install-root.c @@ -548,7 +548,6 @@ static void test_preset_and_list(const char *root) { const char *p, *q; UnitFileState state; bool got_yes = false, got_no = false; - Iterator j; UnitFileList *fl; Hashmap *h; @@ -631,7 +630,7 @@ static void test_preset_and_list(const char *root) { p = strjoina(root, "/usr/lib/systemd/system/preset-yes.service"); q = strjoina(root, "/usr/lib/systemd/system/preset-no.service"); - HASHMAP_FOREACH(fl, h, j) { + HASHMAP_FOREACH(fl, h) { assert_se(unit_file_get_state(UNIT_FILE_SYSTEM, root, basename(fl->path), &state) >= 0); assert_se(fl->state == state); -- cgit v1.2.1