The remount still needs to have MS_BIND set.
authorDaniel Hokka Zakrisson <daniel@hozac.com>
Fri, 3 Apr 2009 16:41:16 +0000 (16:41 +0000)
committerDaniel Hokka Zakrisson <daniel@hozac.com>
Fri, 3 Apr 2009 16:41:16 +0000 (16:41 +0000)
git-svn-id: http://svn.linux-vserver.org/svn/util-vserver/trunk@2832 94cd875c-1c1d-0410-91d2-eb244daf1a30

src/secure-mount.c

index 57fe874..a58edf3 100644 (file)
@@ -448,8 +448,7 @@ mountSingle(struct MountInfo const *mnt, struct Options const *opt)
        return false;
       if (mount(mnt->src, ".",
                mnt->type ? mnt->type : "",
-               ((mnt->flag & ~(MS_BIND|MS_REC)) |
-               MS_REMOUNT), NULL) == -1 &&
+               (mnt->flag | MS_REMOUNT), NULL) == -1 &&
          errno != EBUSY) { /* Returned on older kernels */
        perror("secure-mount: mount()");
        return false;