Revert "dir: non-functional changes"

This reverts commit 8f2896da. Signed-off-by: 's avatarChristian Brauner <christian.brauner@ubuntu.com>
parent b70ffc20
...@@ -43,8 +43,7 @@ int dir_clonepaths(struct bdev *orig, struct bdev *new, const char *oldname, ...@@ -43,8 +43,7 @@ int dir_clonepaths(struct bdev *orig, struct bdev *new, const char *oldname,
size_t len; size_t len;
if (snap) { if (snap) {
ERROR("directories cannot be snapshotted. Try aufs or " ERROR("directories cannot be snapshotted. Try aufs or overlayfs.");
"overlayfs.");
return -1; return -1;
} }
...@@ -151,13 +150,11 @@ int dir_mount(struct bdev *bdev) ...@@ -151,13 +150,11 @@ int dir_mount(struct bdev *bdev)
src = lxc_storage_get_path(bdev->src, bdev->type); src = lxc_storage_get_path(bdev->src, bdev->type);
ret = mount(src, bdev->dest, "bind", MS_BIND | MS_REC | mntflags, ret = mount(src, bdev->dest, "bind", MS_BIND | MS_REC | mntflags, mntdata);
mntdata);
if ((0 == ret) && (mntflags & MS_RDONLY)) { if ((0 == ret) && (mntflags & MS_RDONLY)) {
DEBUG("remounting %s on %s with readonly options", DEBUG("remounting %s on %s with readonly options",
src ? src : "(none)", bdev->dest ? bdev->dest : "(none)"); src ? src : "(none)", bdev->dest ? bdev->dest : "(none)");
mflags = add_required_remount_flags( mflags = add_required_remount_flags(src, bdev->dest, MS_BIND | MS_REC | mntflags | MS_REMOUNT);
src, bdev->dest, MS_BIND | MS_REC | mntflags | MS_REMOUNT);
ret = mount(src, bdev->dest, "bind", mflags, mntdata); ret = mount(src, bdev->dest, "bind", mflags, mntdata);
} }
......
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