From ee20761ea897a097cf46fdb223c0e0f40b1fba91 Mon Sep 17 00:00:00 2001 From: Francesco Giudici Date: Fri, 23 Aug 2019 18:25:23 +0200 Subject: [PATCH] dhcp: prefer nm_assert() to g_assert*() --- src/dhcp/nm-dhcp-client.c | 2 +- src/dhcp/nm-dhcp-dhclient-utils.c | 2 +- src/dhcp/nm-dhcp-dhclient.c | 2 +- 3 files changed, 3 insertions(+), 3 deletions(-) diff --git a/src/dhcp/nm-dhcp-client.c b/src/dhcp/nm-dhcp-client.c index 9f585c5dc9..a134555b87 100644 --- a/src/dhcp/nm-dhcp-client.c +++ b/src/dhcp/nm-dhcp-client.c @@ -686,7 +686,7 @@ nm_dhcp_client_stop (NMDhcpClient *self, gboolean release) _LOGI ("canceled DHCP transaction, DHCP client pid %d", old_pid); else _LOGI ("canceled DHCP transaction"); - g_assert (priv->pid == -1); + nm_assert (priv->pid == -1); nm_dhcp_client_set_state (self, NM_DHCP_STATE_DONE, NULL, NULL); } diff --git a/src/dhcp/nm-dhcp-dhclient-utils.c b/src/dhcp/nm-dhcp-dhclient-utils.c index bf3df399b6..359779f19c 100644 --- a/src/dhcp/nm-dhcp-dhclient-utils.c +++ b/src/dhcp/nm-dhcp-dhclient-utils.c @@ -128,7 +128,7 @@ add_ip4_config (GString *str, GBytes *client_id, const char *hostname, gboolean guint i; p = g_bytes_get_data (client_id, &l); - g_assert (p); + nm_assert (p); /* Allow type 0 (non-hardware address) to be represented as a string * as long as all the characters are printable. diff --git a/src/dhcp/nm-dhcp-dhclient.c b/src/dhcp/nm-dhcp-dhclient.c index 72ea3d48f8..fa142b4b5d 100644 --- a/src/dhcp/nm-dhcp-dhclient.c +++ b/src/dhcp/nm-dhcp-dhclient.c @@ -213,7 +213,7 @@ merge_dhclient_config (NMDhcpDhclient *self, orig_path, orig, out_new_client_id); - g_assert (new); + nm_assert (new); return g_file_set_contents (conf_file, new,