mirror of
https://gitlab.freedesktop.org/NetworkManager/NetworkManager.git
synced 2026-02-18 15:20:37 +01:00
iwd: Initialize priv->scanning when DBus interface appears
This commit is contained in:
parent
e6689154ae
commit
bcf3b10284
1 changed files with 4 additions and 0 deletions
|
|
@ -1733,6 +1733,7 @@ nm_device_iwd_set_dbus_object (NMDeviceIwd *self, GDBusObject *object)
|
|||
{
|
||||
NMDeviceIwdPrivate *priv = NM_DEVICE_IWD_GET_PRIVATE (self);
|
||||
GDBusInterface *interface;
|
||||
gs_unref_variant GVariant *value = NULL;
|
||||
|
||||
if (!nm_g_object_ref_set ((GObject **) &priv->dbus_obj, (GObject *) object))
|
||||
return;
|
||||
|
|
@ -1759,6 +1760,9 @@ nm_device_iwd_set_dbus_object (NMDeviceIwd *self, GDBusObject *object)
|
|||
interface = g_dbus_object_get_interface (object, NM_IWD_DEVICE_INTERFACE);
|
||||
priv->dbus_proxy = G_DBUS_PROXY (interface);
|
||||
|
||||
value = g_dbus_proxy_get_cached_property (priv->dbus_proxy, "Scanning");
|
||||
priv->scanning = g_variant_get_boolean (value);
|
||||
|
||||
g_signal_connect (priv->dbus_proxy, "g-properties-changed",
|
||||
G_CALLBACK (properties_changed), self);
|
||||
|
||||
|
|
|
|||
Loading…
Add table
Reference in a new issue