summaryrefslogtreecommitdiff
path: root/src/applet-device-wifi.c
diff options
context:
space:
mode:
authorLubomir Rintel <lkundrak@v3.sk>2022-03-08 15:38:00 +0100
committerLubomir Rintel <lkundrak@v3.sk>2022-03-08 15:38:00 +0100
commitcfaa38bfae2d4ee89312cd35f142d6a00b7bde75 (patch)
tree38ee8e067eb3f433e20bba5708a3977c8fc24c98 /src/applet-device-wifi.c
parent041077276468333e09313e77927ce722daabd507 (diff)
downloadnetwork-manager-applet-lr/error-dialogs.tar.gz
applet: tidy up the error dialogs a bitlr/error-dialogs
Remove the numeric error code, it doens't belong in the GUI. Before: Failed to activate connection (7) wpa_supplicant doesn't support... After: Failed to activate connection wpa_supplicant doesn't support... While at that, don't spew useless warnings on the stderr.
Diffstat (limited to 'src/applet-device-wifi.c')
-rw-r--r--src/applet-device-wifi.c10
1 files changed, 2 insertions, 8 deletions
diff --git a/src/applet-device-wifi.c b/src/applet-device-wifi.c
index 8de2f667..0a0783b9 100644
--- a/src/applet-device-wifi.c
+++ b/src/applet-device-wifi.c
@@ -1344,12 +1344,9 @@ activate_existing_cb (GObject *client,
g_clear_object (&active);
if (error) {
const char *text = _("Failed to activate connection");
- char *err_text = g_strdup_printf ("(%d) %s", error->code,
- error->message ? error->message : _("Unknown error"));
+ const char *err_text = error->message ? error->message : _("Unknown error");
- g_warning ("%s: %s", text, err_text);
utils_show_error_dialog (_("Connection failure"), text, err_text, FALSE, NULL);
- g_free (err_text);
g_error_free (error);
}
applet_schedule_update_icon (NM_APPLET (user_data));
@@ -1367,12 +1364,9 @@ activate_new_cb (GObject *client,
g_clear_object (&active);
if (error) {
const char *text = _("Failed to add new connection");
- char *err_text = g_strdup_printf ("(%d) %s", error->code,
- error->message ? error->message : _("Unknown error"));
+ const char *err_text = error->message ? error->message : _("Unknown error");
- g_warning ("%s: %s", text, err_text);
utils_show_error_dialog (_("Connection failure"), text, err_text, FALSE, NULL);
- g_free (err_text);
g_error_free (error);
}
applet_schedule_update_icon (NM_APPLET (user_data));