Commit d693cf93 by Stéphane Graber

Fix crash in rename with undefined containers

parent 63d4950f
...@@ -2742,7 +2742,7 @@ static bool lxcapi_rename(struct lxc_container *c, const char *newname) ...@@ -2742,7 +2742,7 @@ static bool lxcapi_rename(struct lxc_container *c, const char *newname)
struct bdev *bdev; struct bdev *bdev;
struct lxc_container *newc; struct lxc_container *newc;
if (!c || !c->name || !c->config_path) if (!c || !c->name || !c->config_path || !c->lxc_conf)
return false; return false;
bdev = bdev_init(c->lxc_conf->rootfs.path, c->lxc_conf->rootfs.mount, NULL); bdev = bdev_init(c->lxc_conf->rootfs.path, c->lxc_conf->rootfs.mount, 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