]> git.ipfire.org Git - thirdparty/systemd.git/commitdiff
locale: drop context_clear_x11() 26292/head
authorYu Watanabe <watanabe.yu+github@gmail.com>
Wed, 1 Feb 2023 18:17:53 +0000 (03:17 +0900)
committerYu Watanabe <watanabe.yu+github@gmail.com>
Wed, 1 Feb 2023 18:59:21 +0000 (03:59 +0900)
It is used at only place, and mostly trivial.
No functional change, just refactoring.

src/locale/localed-util.c

index 3c260d86bdfe46f7922eb9a4bd95f4665105d8c9..8f18ecd0d2fd79cfbed4a260a278772a94624938 100644 (file)
@@ -154,13 +154,6 @@ int x11_context_copy(X11Context *dest, const X11Context *src) {
         return modified;
 }
 
-static void context_clear_x11(Context *c) {
-        assert(c);
-
-        x11_context_clear(&c->x11_from_xorg);
-        x11_context_clear(&c->x11_from_vc);
-}
-
 void vc_context_clear(VCContext *vc) {
         assert(vc);
 
@@ -235,7 +228,8 @@ void context_clear(Context *c) {
         assert(c);
 
         locale_context_clear(&c->locale_context);
-        context_clear_x11(c);
+        x11_context_clear(&c->x11_from_xorg);
+        x11_context_clear(&c->x11_from_vc);
         vc_context_clear(&c->vc);
 
         c->locale_cache = sd_bus_message_unref(c->locale_cache);