mirror of
https://gitlab.freedesktop.org/NetworkManager/NetworkManager.git
synced 2026-01-06 14:20:16 +01:00
wwan: fix wrong connection cast on device state change
nm_settings_connection_set_autoconnect_blocked_reason() must be called
on the settings-connection. Fixes the following:
GLib-GObject-WARNING **: invalid cast from 'NMSimpleConnection' to 'NMSettingsConnection'
Fixes: 06da353242
This commit is contained in:
parent
d860ccfc7b
commit
7034ea7aa3
1 changed files with 2 additions and 2 deletions
|
|
@ -363,7 +363,7 @@ device_state_changed (NMDevice *device,
|
|||
{
|
||||
NMDeviceModem *self = NM_DEVICE_MODEM (device);
|
||||
NMDeviceModemPrivate *priv = NM_DEVICE_MODEM_GET_PRIVATE (self);
|
||||
NMConnection *connection = nm_device_get_applied_connection (device);
|
||||
NMSettingsConnection *connection = nm_device_get_settings_connection (device);
|
||||
|
||||
g_assert (priv->modem);
|
||||
|
||||
|
|
@ -390,7 +390,7 @@ device_state_changed (NMDevice *device,
|
|||
* where a retry attempt would just fail again.
|
||||
*/
|
||||
if (connection)
|
||||
nm_settings_connection_set_autoconnect_blocked_reason (NM_SETTINGS_CONNECTION (connection), reason);
|
||||
nm_settings_connection_set_autoconnect_blocked_reason (connection, reason);
|
||||
break;
|
||||
default:
|
||||
break;
|
||||
|
|
|
|||
Loading…
Add table
Reference in a new issue