storage/dir: retrieve proper source path later

parent 6cf21d91
...@@ -142,11 +142,11 @@ int dir_mount(struct lxc_storage *bdev) ...@@ -142,11 +142,11 @@ int dir_mount(struct lxc_storage *bdev)
if (is_empty_string(bdev->dest)) if (is_empty_string(bdev->dest))
return syserror_set(-EINVAL, "Missing target mountpoint"); return syserror_set(-EINVAL, "Missing target mountpoint");
src = lxc_storage_get_path(bdev->src, bdev->type);
if (rootfs->dfd_idmapped >= 0 && !can_use_bind_mounts()) if (rootfs->dfd_idmapped >= 0 && !can_use_bind_mounts())
return syserror_set(-EOPNOTSUPP, "Idmapped mount requested but kernel doesn't support new mount API"); return syserror_set(-EOPNOTSUPP, "Idmapped mount requested but kernel doesn't support new mount API");
src = lxc_storage_get_path(bdev->src, bdev->type);
if (can_use_bind_mounts()) { if (can_use_bind_mounts()) {
__do_close int fd_source = -EBADF, fd_target = -EBADF; __do_close int fd_source = -EBADF, fd_target = -EBADF;
......
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