core: add free_and_replace() at one more place

This commit is contained in:
Lennart Poettering 2018-10-26 19:33:10 +02:00
parent 7593c3ecbf
commit 6897dfe85a
1 changed files with 1 additions and 2 deletions

View File

@ -4659,8 +4659,7 @@ int exec_command_set(ExecCommand *c, const char *path, ...) {
return -ENOMEM;
}
free(c->path);
c->path = p;
free_and_replace(c->path, p);
return strv_free_and_replace(c->argv, l);
}