---
gdhcp/client.c | 17 +++++++++--------
1 file changed, 9 insertions(+), 8 deletions(-)
diff --git a/gdhcp/client.c b/gdhcp/client.c
index ec61731..e4577b2 100644
--- a/gdhcp/client.c
+++ b/gdhcp/client.c
@@ -2233,17 +2233,18 @@ static void get_request(GDHCPClient *dhcp_client,
struct dhcp_packet *packet)
if (!option_value)
g_hash_table_remove(dhcp_client->code_value_hash,
GINT_TO_POINTER((int) code));
+ else {
+ value_list = get_option_value_list(option_value, type);
- value_list = get_option_value_list(option_value, type);
+ g_free(option_value);
- g_free(option_value);
-
- if (!value_list)
- g_hash_table_remove(dhcp_client->code_value_hash,
+ if (!value_list)
+
g_hash_table_remove(dhcp_client->code_value_hash,
GINT_TO_POINTER((int) code));
- else
- g_hash_table_insert(dhcp_client->code_value_hash,
- GINT_TO_POINTER((int) code), value_list);
+ else
+
g_hash_table_insert(dhcp_client->code_value_hash,
+ GINT_TO_POINTER((int) code),
value_list);
+ }
}
}
--
1.9.1
_______________________________________________
connman mailing list
[email protected]
https://lists.connman.net/mailman/listinfo/connman