From: Karel Zak Date: Mon, 28 May 2012 17:54:16 +0000 (+0200) Subject: mount: (new) fix MS_REC usage X-Git-Tag: v2.22-rc1~360 X-Git-Url: http://git.ipfire.org/cgi-bin/gitweb.cgi?a=commitdiff_plain;h=b0d3657def61d62746257b825ea333beec64f1ce;p=thirdparty%2Futil-linux.git mount: (new) fix MS_REC usage # mount -R /mnt/test /mnt/test mount: propagation flags (--make-* or --bind options) are mutually exclusive Reported-by: Dave Reisner Signed-off-by: Karel Zak --- diff --git a/sys-utils/mount.c b/sys-utils/mount.c index a4fbd9b8fc..2b8843cc7e 100644 --- a/sys-utils/mount.c +++ b/sys-utils/mount.c @@ -902,7 +902,7 @@ int main(int argc, char **argv) usage(stderr); if (oper) { - if (!is_power_of_2(oper)) + if (!is_power_of_2(oper & ~MS_REC)) errx(MOUNT_EX_USAGE, _("propagation flags (--make-* or --bind options) are mutually exclusive")); if (oper != MS_BIND && mnt_context_get_options(cxt))