ryantimwilson / rpms / systemd

Forked from rpms/systemd a month ago
Clone
Blob Blame History Raw
From bc5efb385f238fc7b9cbf552c61269fd680e2c94 Mon Sep 17 00:00:00 2001
From: =?UTF-8?q?Zbigniew=20J=C4=99drzejewski-Szmek?= <zbyszek@in.waw.pl>
Date: Thu, 7 Apr 2022 11:22:08 +0200
Subject: [PATCH] core: inline an iterator variable

(cherry picked from commit 32adc3a7cab85ce543d6895d644a52c6965a274c)

Related: #2087652
---
 src/core/locale-setup.c | 3 +--
 1 file changed, 1 insertion(+), 2 deletions(-)

diff --git a/src/core/locale-setup.c b/src/core/locale-setup.c
index 59ddb9c487..716febbefa 100644
--- a/src/core/locale-setup.c
+++ b/src/core/locale-setup.c
@@ -16,7 +16,6 @@
 int locale_setup(char ***environment) {
         _cleanup_(locale_variables_freep) char *variables[_VARIABLE_LC_MAX] = {};
         _cleanup_strv_free_ char **add = NULL;
-        LocaleVariable i;
         int r;
 
         r = proc_cmdline_get_key_many(PROC_CMDLINE_STRIP_RD_PREFIX,
@@ -58,7 +57,7 @@ int locale_setup(char ***environment) {
                         log_warning_errno(r, "Failed to read /etc/locale.conf: %m");
         }
 
-        for (i = 0; i < _VARIABLE_LC_MAX; i++) {
+        for (LocaleVariable i = 0; i < _VARIABLE_LC_MAX; i++) {
                 char *s;
 
                 if (!variables[i])