lifecycle: Don't leak allocated memory.
Signed-off-by: Maximilian Wilhelm <max@sdn.clinic>
This commit is contained in:
parent
1a2298a759
commit
5302bee850
1 changed files with 4 additions and 0 deletions
|
@ -231,6 +231,10 @@ build_environment(char **envp[], const struct lif_execute_opts *opts, const stru
|
|||
lif_environment_push(envp, "IF_ADDRESSES", addresses);
|
||||
if (gateways != NULL)
|
||||
lif_environment_push(envp, "IF_GATEWAYS", gateways);
|
||||
|
||||
/* Clean up */
|
||||
free (addresses);
|
||||
free (gateways);
|
||||
}
|
||||
|
||||
bool
|
||||
|
|
Loading…
Reference in a new issue