diff options
author | Beniamino Galvani <bgalvani@redhat.com> | 2020-06-18 08:49:15 +0200 |
---|---|---|
committer | Beniamino Galvani <bgalvani@redhat.com> | 2020-06-18 14:25:58 +0200 |
commit | 3ecfd13dedb1260968e07b49423017e7bf328200 (patch) | |
tree | 5b0c01a7201b19fc69d02c2c6765eac159682e5d | |
parent | 3e2135788830396e7142a8201b809074e42889d1 (diff) | |
download | NetworkManager-3ecfd13dedb1260968e07b49423017e7bf328200.tar.gz |
cli: fix reference count handling in hotspot error path
The connection is automatically unreferenced when the function
returns.
Fixes: 9c5ea0917d51 ('devices: reuse the hotspot connection if we find appropriate one'):
-rw-r--r-- | clients/cli/devices.c | 1 |
1 files changed, 0 insertions, 1 deletions
diff --git a/clients/cli/devices.c b/clients/cli/devices.c index e83d3472c3..27f72e7787 100644 --- a/clients/cli/devices.c +++ b/clients/cli/devices.c @@ -4192,7 +4192,6 @@ do_device_wifi_hotspot (const NMCCommand *cmd, NmCli *nmc, int argc, const char g_return_if_fail (s_wsec); if (!set_wireless_security_for_hotspot (s_wsec, wifi_mode, caps, password, show_password, &error)) { - g_object_unref (connection); g_string_printf (nmc->return_text, _("Error: Invalid 'password': %s."), error->message); g_clear_error (&error); nmc->return_value = NMC_RESULT_ERROR_UNKNOWN; |