summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorThomas Haller <thaller@redhat.com>2022-12-13 08:36:59 +0100
committerThomas Haller <thaller@redhat.com>2022-12-19 11:29:13 +0100
commitccbe76b81d2bb49d290b01dcf5e9f391279115c6 (patch)
tree95bcf8b7413ceadb613fcbdacef95abd072aa5f9
parent492818b52940f70d4fd7c553c07770030b56de2e (diff)
downloadNetworkManager-ccbe76b81d2bb49d290b01dcf5e9f391279115c6.tar.gz
dhcp: use nm_dhcp_option_create_options_dict() in nm_dhcp_client_handle_event()
The point of using this trivial helper function is to have one function that is related to the construction of the options dictionary, that we can search for. It answers the question, where do we create a option hash (at `git grep nm_dhcp_option_create_options_dict`).
-rw-r--r--src/core/dhcp/nm-dhcp-client.c2
1 files changed, 1 insertions, 1 deletions
diff --git a/src/core/dhcp/nm-dhcp-client.c b/src/core/dhcp/nm-dhcp-client.c
index c450f355a5..850ec34984 100644
--- a/src/core/dhcp/nm-dhcp-client.c
+++ b/src/core/dhcp/nm-dhcp-client.c
@@ -1613,7 +1613,7 @@ nm_dhcp_client_handle_event(gpointer unused,
GVariant *value;
/* Copy options */
- str_options = g_hash_table_new_full(nm_str_hash, g_str_equal, g_free, g_free);
+ str_options = nm_dhcp_option_create_options_dict(FALSE);
g_variant_iter_init(&iter, options);
while (g_variant_iter_next(&iter, "{&sv}", &name, &value)) {
maybe_add_option(self, str_options, name, value);