lxccontainer: remove pointless string duplication

parent 6e1a327a
...@@ -1185,7 +1185,6 @@ WRAP_API(bool, lxcapi_stop) ...@@ -1185,7 +1185,6 @@ WRAP_API(bool, lxcapi_stop)
static int do_create_container_dir(const char *path, struct lxc_conf *conf) static int do_create_container_dir(const char *path, struct lxc_conf *conf)
{ {
__do_free char *p = NULL;
int lasterr; int lasterr;
int ret = -1; int ret = -1;
...@@ -1201,10 +1200,8 @@ static int do_create_container_dir(const char *path, struct lxc_conf *conf) ...@@ -1201,10 +1200,8 @@ static int do_create_container_dir(const char *path, struct lxc_conf *conf)
ret = 0; ret = 0;
} }
p = must_copy_string(path);
if (!lxc_list_empty(&conf->id_map)) { if (!lxc_list_empty(&conf->id_map)) {
ret = chown_mapped_root(p, conf); ret = chown_mapped_root(path, conf);
if (ret < 0) if (ret < 0)
ret = -1; ret = -1;
} }
......
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment