Commit 03cd5070 authored by Andrew Vagin's avatar Andrew Vagin Committed by Pavel Emelyanov

criu: don't interrupt do_new_mount() after appling mount options

Reported-by: 's avatarStanislav Kinsburskiy <skinsbursky@virtuozzo.com>
Cc: Stanislav Kinsburskiy <skinsbursky@virtuozzo.com>
Signed-off-by: 's avatarAndrew Vagin <avagin@virtuozzo.com>
Signed-off-by: 's avatarPavel Emelyanov <xemul@virtuozzo.com>
parent c2ff0418
...@@ -2395,9 +2395,11 @@ static int do_new_mount(struct mount_info *mi) ...@@ -2395,9 +2395,11 @@ static int do_new_mount(struct mount_info *mi)
if (tp->restore && tp->restore(mi)) if (tp->restore && tp->restore(mi))
return -1; return -1;
if (remount_ro) if (remount_ro && mount(NULL, mi->mountpoint, tp->name,
return mount(NULL, mi->mountpoint, tp->name, MS_REMOUNT | MS_RDONLY, NULL)) {
MS_REMOUNT | MS_RDONLY, NULL); pr_perror("Unable to apply mount options");
return -1;
}
if (mflags && mount(NULL, mi->mountpoint, NULL, if (mflags && mount(NULL, mi->mountpoint, NULL,
MS_REMOUNT | MS_BIND | mflags, NULL)) { MS_REMOUNT | MS_BIND | mflags, 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