cleanups; outsourced some macros/inlines to libinternal.a
[util-vserver.git] / util-vserver / src / secure-mount.c
index 81fee1f..7a48ff3 100644 (file)
@@ -94,12 +94,17 @@ CMDLINE_OPTIONS[] = {
   { 0, 0, 0, 0 }
 };
 
+#ifndef MS_REC
+#  define MS_REC       0x4000
+#endif
+
 static struct FstabOptions {
     char const * const opt;
     unsigned long const        or_flag;
     unsigned long const        and_flag;
     bool const         is_dflt;
 } const FSTAB_OPTIONS[] = {
+  { "rbind",      MS_BIND|MS_REC, ~0, false },
   { "bind",       MS_BIND,        ~0, false },
   { "move",       MS_MOVE,        ~0, false },
 #if 0
@@ -375,7 +380,7 @@ mountSingle(struct MountInfo const *mnt, struct Options const *opt)
     }
   }
 
-  if (mnt->flags&MS_BIND) {
+  if (mnt->flags & (MS_BIND|MS_MOVE)) {
     if (mount(mnt->src, ".",
              mnt->type ? mnt->type : "",
              mnt->flags, mnt->data)==-1) {