]> git.ipfire.org Git - thirdparty/systemd.git/commitdiff
locale: drop unnecessary allocation
authorYu Watanabe <watanabe.yu+github@gmail.com>
Sat, 18 Jun 2022 02:06:46 +0000 (11:06 +0900)
committerLuca Boccassi <luca.boccassi@gmail.com>
Sat, 18 Jun 2022 13:46:45 +0000 (14:46 +0100)
Fixes a bug introduced by 3d36b5d7e7b191fca7c5c65dbab94d99cf5f0230.

Fixes #23777.

src/locale/localed.c

index 2c324efb148e27f7eb1e0e303d6d9980371c174c..791b5e60dd8d4fb992535e36fd93fce7f79484ef 100644 (file)
@@ -152,10 +152,6 @@ static int property_get_locale(
         if (r < 0)
                 return r;
 
-        l = new0(char*, _VARIABLE_LC_MAX+1);
-        if (!l)
-                return -ENOMEM;
-
         r = locale_context_build_env(&c->locale_context, &l, NULL);
         if (r < 0)
                 return r;