about summary refs log tree commit diff
path: root/src/core/nm-dispatcher.c
diff options
context:
space:
mode:
authorMichael Biebl <biebl@debian.org>2021-10-01 23:06:08 +0200
committerMichael Biebl <biebl@debian.org>2021-10-01 23:06:08 +0200
commita3349a04ac4c38885cddefec8515c979d03f9327 (patch)
treed3bbee695aa048cb4ec252e7d63515c8376f9006 /src/core/nm-dispatcher.c
parent2d5b58e374d67f60880c7689e80c7745aeef3f62 (diff)
parente74c568b07b50b97873fb4ee1d776dedefbd54d6 (diff)
Update upstream source from tag 'upstream/1.32.12'
Update to upstream version '1.32.12'
with Debian dir 6fabefa95c7dcf83371a78eb2c47013a81ff8d86
Diffstat (limited to 'src/core/nm-dispatcher.c')
-rw-r--r--src/core/nm-dispatcher.c24
1 files changed, 9 insertions, 15 deletions
diff --git a/src/core/nm-dispatcher.c b/src/core/nm-dispatcher.c
index 0ab409f5..32c9db62 100644
--- a/src/core/nm-dispatcher.c
+++ b/src/core/nm-dispatcher.c
@@ -8,7 +8,7 @@
 
 #include "nm-dispatcher.h"
 
-#include "nm-libnm-core-aux/nm-dispatcher-api.h"
+#include "libnm-core-aux-extern/nm-dispatcher-api.h"
 #include "NetworkManagerUtils.h"
 #include "nm-utils.h"
 #include "nm-connectivity.h"
@@ -20,8 +20,8 @@
 #include "nm-ip6-config.h"
 #include "nm-manager.h"
 #include "settings/nm-settings-connection.h"
-#include "platform/nm-platform.h"
-#include "nm-core-internal.h"
+#include "libnm-platform/nm-platform.h"
+#include "libnm-core-intern/nm-core-internal.h"
 
 #define CALL_TIMEOUT (1000 * 60 * 10) /* 10 minutes for all scripts */
 
@@ -206,10 +206,7 @@ dump_ip_to_props(NMIPConfig *ip, GVariantBuilder *builder)
             array[0] = addr->a4.address;
             array[1] = addr->a4.plen;
             array[2] = gw;
-            g_variant_builder_add(
-                &int_builder,
-                "@au",
-                g_variant_new_fixed_array(G_VARIANT_TYPE_UINT32, array, 3, sizeof(guint32)));
+            g_variant_builder_add(&int_builder, "@au", nm_g_variant_new_au(array, 3));
         } else {
             const struct in6_addr *gw = &in6addr_any;
 
@@ -278,10 +275,7 @@ dump_ip_to_props(NMIPConfig *ip, GVariantBuilder *builder)
             array[1] = route->r4.plen;
             array[2] = route->r4.gateway;
             array[3] = route->r4.metric;
-            g_variant_builder_add(
-                &int_builder,
-                "@au",
-                g_variant_new_fixed_array(G_VARIANT_TYPE_UINT32, array, 4, sizeof(guint32)));
+            g_variant_builder_add(&int_builder, "@au", nm_g_variant_new_au(array, 4));
         } else {
             var1 = nm_g_variant_new_ay_in6addr(&route->r6.network);
             var2 = nm_g_variant_new_ay_in6addr(&route->r6.gateway);
@@ -550,9 +544,9 @@ _dispatcher_call(NMDispatcherAction    action,
 
     if (applied_connection)
         connection_dict =
-            nm_connection_to_dbus(applied_connection, NM_CONNECTION_SERIALIZE_NO_SECRETS);
+            nm_connection_to_dbus(applied_connection, NM_CONNECTION_SERIALIZE_WITH_NON_SECRET);
     else
-        connection_dict = g_variant_new_array(G_VARIANT_TYPE("{sa{sv}}"), NULL, 0);
+        connection_dict = nm_g_variant_singleton_aLsaLsvII();
 
     g_variant_builder_init(&connection_props, G_VARIANT_TYPE_VARDICT);
     if (settings_connection) {
@@ -620,8 +614,8 @@ _dispatcher_call(NMDispatcherAction    action,
                       &device_proxy_props,
                       &device_ip4_props,
                       &device_ip6_props,
-                      device_dhcp4_props ?: g_variant_new_array(G_VARIANT_TYPE("{sv}"), NULL, 0),
-                      device_dhcp6_props ?: g_variant_new_array(G_VARIANT_TYPE("{sv}"), NULL, 0),
+                      device_dhcp4_props ?: nm_g_variant_singleton_aLsvI(),
+                      device_dhcp6_props ?: nm_g_variant_singleton_aLsvI(),
                       connectivity_state_string,
                       vpn_iface ?: "",
                       &vpn_proxy_props,