mirror of
https://gitlab.freedesktop.org/NetworkManager/NetworkManager.git
synced 2026-01-06 10:50:14 +01:00
dhcp: don't leak dhclient config file contents when merging
If there was an existing dhclient config file, don't leak it when merging to the new configuration. Found by Mathieu Trudel-Lapierre <mathieu@canonical.com>
This commit is contained in:
parent
0a85eefd8c
commit
228224a072
1 changed files with 1 additions and 0 deletions
|
|
@ -334,6 +334,7 @@ merge_dhclient_config (const char *iface,
|
|||
g_assert (new);
|
||||
success = g_file_set_contents (conf_file, new, -1, error);
|
||||
g_free (new);
|
||||
g_free (orig);
|
||||
|
||||
return success;
|
||||
}
|
||||
|
|
|
|||
Loading…
Add table
Reference in a new issue