mirror of
https://gitlab.freedesktop.org/NetworkManager/NetworkManager.git
synced 2026-06-05 17:08:21 +02:00
ovs: don't leak a GCancellable on connection failure
Every time we clear priv->client we should also clear the cancellable
or it will be leaked.
Fixes: 830a5a14cb
This commit is contained in:
parent
139b9974fa
commit
b92f2c9323
1 changed files with 1 additions and 3 deletions
|
|
@ -1308,6 +1308,7 @@ ovsdb_disconnect (NMOvsdb *self, gboolean is_disposing)
|
|||
g_clear_object (&priv->client);
|
||||
g_clear_object (&priv->conn);
|
||||
g_clear_pointer (&priv->db_uuid, g_free);
|
||||
nm_clear_g_cancellable (&priv->cancellable);
|
||||
}
|
||||
|
||||
static void
|
||||
|
|
@ -1540,9 +1541,6 @@ dispose (GObject *object)
|
|||
g_clear_pointer (&priv->ports, g_hash_table_destroy);
|
||||
g_clear_pointer (&priv->interfaces, g_hash_table_destroy);
|
||||
|
||||
g_cancellable_cancel (priv->cancellable);
|
||||
g_clear_object (&priv->cancellable);
|
||||
|
||||
G_OBJECT_CLASS (nm_ovsdb_parent_class)->dispose (object);
|
||||
}
|
||||
|
||||
|
|
|
|||
Loading…
Add table
Reference in a new issue