[gnome-control-center] network: Replace deprecated nm_device_disconnect



commit c23c56a0a15b9f33aed664e779fbc5061eea3304
Author: Robert Ancell <robert ancell canonical com>
Date:   Tue May 31 15:35:03 2022 +1200

    network: Replace deprecated nm_device_disconnect

 panels/network/net-device-ethernet.c | 2 +-
 panels/network/net-device-mobile.c   | 2 +-
 2 files changed, 2 insertions(+), 2 deletions(-)
---
diff --git a/panels/network/net-device-ethernet.c b/panels/network/net-device-ethernet.c
index ead711cf1..3cf64b0b4 100644
--- a/panels/network/net-device-ethernet.c
+++ b/panels/network/net-device-ethernet.c
@@ -439,7 +439,7 @@ device_off_switch_changed_cb (NetDeviceEthernet *self)
                                                              NULL, NULL, NULL, NULL);
                 }
         } else {
-                nm_device_disconnect (self->device, NULL, NULL);
+                nm_device_disconnect_async (self->device, NULL, NULL, NULL);
         }
 }
 
diff --git a/panels/network/net-device-mobile.c b/panels/network/net-device-mobile.c
index 5dc677d91..46604934c 100644
--- a/panels/network/net-device-mobile.c
+++ b/panels/network/net-device-mobile.c
@@ -130,7 +130,7 @@ network_combo_changed_cb (NetDeviceMobile *self)
         g_debug ("try to switch to connection %s", object_path);
         connection = (NMConnection*) nm_client_get_connection_by_path (self->client, object_path);
         if (connection != NULL) {
-                nm_device_disconnect (self->device, NULL, NULL);
+                nm_device_disconnect_async (self->device, NULL, NULL, NULL);
                 nm_client_activate_connection_async (self->client,
                                                      connection,
                                                      self->device, NULL, NULL,


[Date Prev][Date Next]   [Thread Prev][Thread Next]   [Thread Index] [Date Index] [Author Index]