From ea13cff76c9d5942f6ced41669297f77fea08a6a Mon Sep 17 00:00:00 2001 From: Thomas Haller Date: Tue, 10 May 2022 21:35:52 +0200 Subject: [PATCH] dhcp: assert that resources are freed in NMDhcpClient.dispose() --- src/core/dhcp/nm-dhcp-client.c | 4 ++++ 1 file changed, 4 insertions(+) diff --git a/src/core/dhcp/nm-dhcp-client.c b/src/core/dhcp/nm-dhcp-client.c index d793aaed7a..390bb594bf 100644 --- a/src/core/dhcp/nm-dhcp-client.c +++ b/src/core/dhcp/nm-dhcp-client.c @@ -1206,6 +1206,10 @@ dispose(GObject *object) nm_clear_g_source_inst(&priv->ipv6_lladdr_timeout_source); nm_clear_pointer(&priv->effective_client_id, g_bytes_unref); + nm_assert(!priv->watch_source); + nm_assert(!priv->l3cd); + nm_assert(priv->l3cfg_notify.id == 0); + G_OBJECT_CLASS(nm_dhcp_client_parent_class)->dispose(object); }