mirror of
https://gitlab.freedesktop.org/NetworkManager/NetworkManager.git
synced 2025-12-25 10:40:08 +01:00
dhcp: don't assert against untrusted data in maybe_add_option()
This commit is contained in:
parent
668d8050a5
commit
cb2ab420a2
1 changed files with 2 additions and 1 deletions
|
|
@ -814,7 +814,8 @@ maybe_add_option(NMDhcpClient *self, GHashTable *hash, const char *key, GVariant
|
|||
{
|
||||
char *str_value = NULL;
|
||||
|
||||
g_return_if_fail(g_variant_is_of_type(value, G_VARIANT_TYPE_BYTESTRING));
|
||||
if (!g_variant_is_of_type(value, G_VARIANT_TYPE_BYTESTRING))
|
||||
return;
|
||||
|
||||
if (g_str_has_prefix(key, OLD_TAG))
|
||||
return;
|
||||
|
|
|
|||
Loading…
Add table
Reference in a new issue