Skip to content

Commit

Permalink
mount: print an error if a root can't be bind-mounted
Browse files Browse the repository at this point in the history
  • Loading branch information
avagin committed Feb 23, 2017
1 parent 45241fc commit 204f44d
Showing 1 changed file with 3 additions and 1 deletion.
4 changes: 3 additions & 1 deletion criu/mount.c
Expand Up @@ -2102,8 +2102,10 @@ static int do_mount_one(struct mount_info *mi)

if (rst_mnt_is_root(mi)) {
/* do_mount_root() is called from populate_mnt_ns() */
if (mount(opts.root, mi->mountpoint, NULL, MS_BIND | MS_REC, NULL))
if (mount(opts.root, mi->mountpoint, NULL, MS_BIND | MS_REC, NULL)) {
pr_perror("Unable to mount %s %s\n", opts.root, mi->mountpoint);
return -1;
}
if (do_mount_root(mi))
return -1;
mi->mounted = true;
Expand Down

0 comments on commit 204f44d

Please sign in to comment.