mirror of
https://gitlab.freedesktop.org/NetworkManager/NetworkManager.git
synced 2026-01-13 19:00:28 +01:00
cloud-setup: fix allocating buffer for GetConfigMetadataMac in _get_config_metadata_ready_check()
It's not a severe issue, because the GetConfigMetadataData struct is larger than GetConfigMetadataMac. Fixes:69f048bf0c('cloud-setup: add tool for automatic IP configuration in cloud') (cherry picked from commit460afe6d50) (cherry picked from commit181fd5c611)
This commit is contained in:
parent
4588e2e817
commit
9fed652db4
1 changed files with 1 additions and 1 deletions
|
|
@ -484,7 +484,7 @@ _get_config_metadata_ready_check (long response_code,
|
|||
if (!response_parsed)
|
||||
response_parsed = g_hash_table_new_full (nm_str_hash, g_str_equal, g_free, g_free);
|
||||
|
||||
mac_data = g_malloc (sizeof (GetConfigMetadataData) + 1 + p_start_l);
|
||||
mac_data = g_malloc (sizeof (GetConfigMetadataMac) + 1 + p_start_l);
|
||||
mac_data->iface_idx = iface_idx_counter++;
|
||||
memcpy (mac_data->path, p_start, p_start_l);
|
||||
mac_data->path[p_start_l] = '\0';
|
||||
|
|
|
|||
Loading…
Add table
Reference in a new issue