lxccontainer: lxc_container_free()

parent a3740e80
...@@ -253,22 +253,28 @@ static void lxc_container_free(struct lxc_container *c) ...@@ -253,22 +253,28 @@ static void lxc_container_free(struct lxc_container *c)
free(c->configfile); free(c->configfile);
c->configfile = NULL; c->configfile = NULL;
free(c->error_string); free(c->error_string);
c->error_string = NULL; c->error_string = NULL;
if (c->slock) { if (c->slock) {
lxc_putlock(c->slock); lxc_putlock(c->slock);
c->slock = NULL; c->slock = NULL;
} }
if (c->privlock) { if (c->privlock) {
lxc_putlock(c->privlock); lxc_putlock(c->privlock);
c->privlock = NULL; c->privlock = NULL;
} }
free(c->name); free(c->name);
c->name = NULL; c->name = NULL;
if (c->lxc_conf) { if (c->lxc_conf) {
lxc_conf_free(c->lxc_conf); lxc_conf_free(c->lxc_conf);
c->lxc_conf = NULL; c->lxc_conf = NULL;
} }
free(c->config_path); free(c->config_path);
c->config_path = NULL; c->config_path = NULL;
......
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