diff options
| author | Michael Biebl <biebl@debian.org> | 2020-06-28 18:59:08 +0200 |
|---|---|---|
| committer | Michael Biebl <biebl@debian.org> | 2020-06-28 18:59:08 +0200 |
| commit | 215112eefc83274273a10d9ddb5e107c9beec548 (patch) | |
| tree | a16052cef4bb8707d6a906dd784a50c75945d03e /clients/tui | |
| parent | 5ed4e66e01b005212aee22c255c9c6b2a4b040a9 (diff) | |
| parent | a54ac63bbf9b2c71026ac9028a8ffaf186cf3c82 (diff) | |
Update upstream source from tag 'upstream/1.25.90'
Update to upstream version '1.25.90' with Debian dir 16d4caa71e8ba8c27ee163c88f11456b6cdc0490
Diffstat (limited to 'clients/tui')
| -rw-r--r-- | clients/tui/nmtui-connect.c | 13 |
1 files changed, 12 insertions, 1 deletions
diff --git a/clients/tui/nmtui-connect.c b/clients/tui/nmtui-connect.c index 1ea20305..ea332096 100644 --- a/clients/tui/nmtui-connect.c +++ b/clients/tui/nmtui-connect.c @@ -222,6 +222,17 @@ add_and_activate_callback (GObject *client, } static void +deactivate_connection (NMActiveConnection *ac) +{ + GError *error = NULL; + + if (!nm_client_deactivate_connection (nm_client, ac, NULL, &error)) { + nmt_newt_message_dialog (_("Could not deactivate connection: %s"), error->message); + g_clear_error (&error); + } +} + +static void activate_connection (NMConnection *connection, NMDevice *device, NMObject *specific_object) @@ -349,7 +360,7 @@ listbox_activated (NmtNewtListbox *listbox, return; if (ac) - nm_client_deactivate_connection (nm_client, ac, NULL, NULL); + deactivate_connection (ac); else activate_connection (connection, device, specific_object); } |