diff options
author | Dan Winship <danw@gnome.org> | 2014-05-15 14:25:07 -0400 |
---|---|---|
committer | Dan Winship <danw@gnome.org> | 2014-08-01 14:34:40 -0400 |
commit | 258e74eb0c191cdd86719ad65864ab3c27ada80c (patch) | |
tree | 29d5a0d72ca94d1ea7daaa6c19ef745db31806fd /libnm/nm-device-ethernet.c | |
parent | 8ca2998d81ca7534c59262b10f5bf3c480177b88 (diff) | |
download | NetworkManager-258e74eb0c191cdd86719ad65864ab3c27ada80c.tar.gz |
libnm: make the the use of GInitable mandatory
Remove _nm_object_ensure_inited(), etc; objects that implement
GInitable are now mandatory-to-init().
Remove constructor() implementations that sometimes return NULL; do
all the relevant checking in init() instead.
Make nm_client_new() and nm_remote_settings_new() take a GCancellable
and a GError**.
Diffstat (limited to 'libnm/nm-device-ethernet.c')
-rw-r--r-- | libnm/nm-device-ethernet.c | 6 |
1 files changed, 0 insertions, 6 deletions
diff --git a/libnm/nm-device-ethernet.c b/libnm/nm-device-ethernet.c index b022786a06..8990062356 100644 --- a/libnm/nm-device-ethernet.c +++ b/libnm/nm-device-ethernet.c @@ -87,7 +87,6 @@ nm_device_ethernet_get_hw_address (NMDeviceEthernet *device) { g_return_val_if_fail (NM_IS_DEVICE_ETHERNET (device), NULL); - _nm_object_ensure_inited (NM_OBJECT (device)); return NM_DEVICE_ETHERNET_GET_PRIVATE (device)->hw_address; } @@ -105,7 +104,6 @@ nm_device_ethernet_get_permanent_hw_address (NMDeviceEthernet *device) { g_return_val_if_fail (NM_IS_DEVICE_ETHERNET (device), NULL); - _nm_object_ensure_inited (NM_OBJECT (device)); return NM_DEVICE_ETHERNET_GET_PRIVATE (device)->perm_hw_address; } @@ -122,7 +120,6 @@ nm_device_ethernet_get_speed (NMDeviceEthernet *device) { g_return_val_if_fail (NM_IS_DEVICE_ETHERNET (device), 0); - _nm_object_ensure_inited (NM_OBJECT (device)); return NM_DEVICE_ETHERNET_GET_PRIVATE (device)->speed; } @@ -139,7 +136,6 @@ nm_device_ethernet_get_carrier (NMDeviceEthernet *device) { g_return_val_if_fail (NM_IS_DEVICE_ETHERNET (device), FALSE); - _nm_object_ensure_inited (NM_OBJECT (device)); return NM_DEVICE_ETHERNET_GET_PRIVATE (device)->carrier; } @@ -268,8 +264,6 @@ get_property (GObject *object, { NMDeviceEthernet *device = NM_DEVICE_ETHERNET (object); - _nm_object_ensure_inited (NM_OBJECT (object)); - switch (prop_id) { case PROP_HW_ADDRESS: g_value_set_string (value, nm_device_ethernet_get_hw_address (device)); |