diff options
author | Thomas Haller <thaller@redhat.com> | 2015-11-18 22:03:00 +0100 |
---|---|---|
committer | Thomas Haller <thaller@redhat.com> | 2015-11-19 13:45:14 +0100 |
commit | 5de28d4d16a61cfe271cfd81aa536927ab5d6875 (patch) | |
tree | 1bbb3f45a6df8b1d53497849ee57239205cedf77 /src/supplicant-manager/nm-supplicant-config.h | |
parent | 98e419496380758d8942606a96eaa199f5c7d10f (diff) | |
download | NetworkManager-5de28d4d16a61cfe271cfd81aa536927ab5d6875.tar.gz |
wifi: propagte errors from supplicant-config to caller
The nm_supplicant_config_add_*() functions used to log failures
themselves. As also the caller was logging the failure this resulted
in duplicate logging lines like:
<warn> MAC address randomization is not supported
<error> [1447867727.909185] [nm-device-wifi.c:2238] build_supplicant_config(): (wlp3s0): Couldn't add 802-11-wireless setting to supplicant config.
<error> [1447867727.909261] [nm-device-wifi.c:2472] act_stage2_config(): (wlp3s0): Activation: (wifi) couldn't build wireless configuration.
Instead, propagate the error reason back to the caller where there
is more context to log one single concise message.
Now you'd see only:
<error> [1447935996.859371] [nm-device-wifi.c:2475] act_stage2_config(): (wlp3s0): Activation: (wifi) couldn't build wireless configuration: 802-11-wireless: cannot enable mac-randomization due to missing supplicant support
Diffstat (limited to 'src/supplicant-manager/nm-supplicant-config.h')
-rw-r--r-- | src/supplicant-manager/nm-supplicant-config.h | 12 |
1 files changed, 8 insertions, 4 deletions
diff --git a/src/supplicant-manager/nm-supplicant-config.h b/src/supplicant-manager/nm-supplicant-config.h index b87edb43b0..921bc16cbc 100644 --- a/src/supplicant-manager/nm-supplicant-config.h +++ b/src/supplicant-manager/nm-supplicant-config.h @@ -66,21 +66,25 @@ gboolean nm_supplicant_config_add_setting_wireless (NMSupplicantConfig *self, NMSettingWireless *setting, guint32 fixed_freq, NMSupplicantFeature mac_randomization_support, - NMSettingMacRandomization mac_randomization_fallback); + NMSettingMacRandomization mac_randomization_fallback, + GError **error); gboolean nm_supplicant_config_add_setting_wireless_security (NMSupplicantConfig *self, NMSettingWirelessSecurity *setting, NMSetting8021x *setting_8021x, const char *con_uuid, - guint32 mtu); + guint32 mtu, + GError **error); -gboolean nm_supplicant_config_add_no_security (NMSupplicantConfig *self); +gboolean nm_supplicant_config_add_no_security (NMSupplicantConfig *self, + GError **error); gboolean nm_supplicant_config_add_setting_8021x (NMSupplicantConfig *self, NMSetting8021x *setting, const char *con_uuid, guint32 mtu, - gboolean wired); + gboolean wired, + GError **error); G_END_DECLS |