diff options
author | Thomas Haller <thaller@redhat.com> | 2017-11-02 16:00:41 +0100 |
---|---|---|
committer | Thomas Haller <thaller@redhat.com> | 2017-11-08 11:33:32 +0100 |
commit | 9a7e668dbb552667e2545953a325d1d041fa0518 (patch) | |
tree | 99996c8a159db5403bad067185dc3fae5e0edc57 | |
parent | 80687ed0cedf3d4eeb32459eb6350d5e4e3428ae (diff) | |
download | NetworkManager-9a7e668dbb552667e2545953a325d1d041fa0518.tar.gz |
device: drop stub implementation of get_autoconnect_allowed() in NMDevice
-rw-r--r-- | src/devices/nm-device.c | 14 | ||||
-rw-r--r-- | src/devices/wifi/nm-device-wifi.c | 3 |
2 files changed, 5 insertions, 12 deletions
diff --git a/src/devices/nm-device.c b/src/devices/nm-device.c index e979b87541..3c1a2c7ea1 100644 --- a/src/devices/nm-device.c +++ b/src/devices/nm-device.c @@ -4272,12 +4272,6 @@ nm_device_set_autoconnect_both (NMDevice *self, gboolean autoconnect) } static gboolean -get_autoconnect_allowed (NMDevice *self) -{ - return TRUE; -} - -static gboolean autoconnect_allowed_accumulator (GSignalInvocationHint *ihint, GValue *return_accu, const GValue *handler_return, gpointer data) @@ -4303,8 +4297,11 @@ nm_device_autoconnect_allowed (NMDevice *self) GValue instance = G_VALUE_INIT; GValue retval = G_VALUE_INIT; - if ( !nm_device_get_autoconnect (self) - || !klass->get_autoconnect_allowed (self)) + if (!nm_device_get_autoconnect (self)) + return FALSE; + + if ( klass->get_autoconnect_allowed + && !klass->get_autoconnect_allowed (self)) return FALSE; /* Unrealized devices can always autoconnect. */ @@ -14668,7 +14665,6 @@ nm_device_class_init (NMDeviceClass *klass) klass->act_stage4_ip6_config_timeout = act_stage4_ip6_config_timeout; klass->get_type_description = get_type_description; - klass->get_autoconnect_allowed = get_autoconnect_allowed; klass->can_auto_connect = can_auto_connect; klass->check_connection_compatible = check_connection_compatible; klass->check_connection_available = check_connection_available; diff --git a/src/devices/wifi/nm-device-wifi.c b/src/devices/wifi/nm-device-wifi.c index 8bfddbd924..5e92f47b76 100644 --- a/src/devices/wifi/nm-device-wifi.c +++ b/src/devices/wifi/nm-device-wifi.c @@ -997,9 +997,6 @@ get_autoconnect_allowed (NMDevice *device) { NMDeviceWifiPrivate *priv; - if (!NM_DEVICE_CLASS (nm_device_wifi_parent_class)->get_autoconnect_allowed (device)) - return FALSE; - priv = NM_DEVICE_WIFI_GET_PRIVATE (NM_DEVICE_WIFI (device)); return !priv->requested_scan; } |