From d2b0c5af6378adbb0fb3c47fea41d2ddd17a6a50 Mon Sep 17 00:00:00 2001 From: Andrew Zaborowski Date: Tue, 6 Oct 2020 01:30:26 +0200 Subject: [PATCH] iwd: Disconnect signals in NMDeviceIwd's dispose Fix a crash on device unplugging caused by keeping our signal handlers for GDBusProxies connected after a call to dispose(). Do this by replacing most cleanup steps by a nm_device_iwd_set_dbus_object(self, NULL) call which is more meticulous. reason:Disconnect signals in NMDeviceIwd's dispose Conflict:NA Reference:https://gitlab.freedesktop.org/NetworkManager/NetworkManager/-/commit/d2b0c5af6378adbb0fb3c47fea41d2ddd17a6a50 --- src/devices/wifi/nm-device-iwd.c | 12 +----------- 1 file changed, 1 insertion(+), 11 deletions(-) diff -Naur a/src/devices/wifi/nm-device-iwd.c b/src/devices/wifi/nm-device-iwd.c --- a/src/devices/wifi/nm-device-iwd.c 2021-02-22 11:15:41.034000000 +0800 +++ b/src/devices/wifi/nm-device-iwd.c 2021-02-22 16:31:18.817000000 +0800 @@ -2573,17 +2573,7 @@ nm_clear_g_cancellable (&priv->cancellable); - nm_clear_g_source (&priv->periodic_scan_id); - - cleanup_association_attempt (self, TRUE); - - g_clear_object (&priv->dbus_device_proxy); - g_clear_object (&priv->dbus_station_proxy); - g_clear_object (&priv->dbus_ap_proxy); - g_clear_object (&priv->dbus_adhoc_proxy); - g_clear_object (&priv->dbus_obj); - - remove_all_aps (self); + nm_device_iwd_set_dbus_object(self, NULL); G_OBJECT_CLASS (nm_device_iwd_parent_class)->dispose (object);