util-linux.vger.kernel.org archive mirror
 help / color / mirror / Atom feed
From: Joshua Watt <jpewhacker@gmail.com>
To: util-linux@vger.kernel.org
Cc: Joshua Watt <JPEWhacker@gmail.com>
Subject: [PATCH] libmount: Allow MNT_FORCE and MNT_DETACH at umount
Date: Mon,  6 Nov 2017 16:25:36 -0600	[thread overview]
Message-ID: <20171106222536.9806-1-JPEWhacker@gmail.com> (raw)

MNT_FORCE and MNT_DETACH are orthogonal in the Linux kernel, so both may
be specified without any problems. Even if there were a problem with
this combination, it should be up to the kernel to take the correct
action or report an error.

Signed-off-by: Joshua Watt <JPEWhacker@gmail.com>
---
 libmount/src/context_umount.c | 2 +-
 1 file changed, 1 insertion(+), 1 deletion(-)

diff --git a/libmount/src/context_umount.c b/libmount/src/context_umount.c
index f6b4ba737..45651b58e 100644
--- a/libmount/src/context_umount.c
+++ b/libmount/src/context_umount.c
@@ -704,7 +704,7 @@ static int do_umount(struct libmnt_context *cxt)
 	if (mnt_context_is_lazy(cxt))
 		flags |= MNT_DETACH;
 
-	else if (mnt_context_is_force(cxt))
+	if (mnt_context_is_force(cxt))
 		flags |= MNT_FORCE;
 
 	DBG(CXT, ul_debugobj(cxt, "umount(2) [target='%s', flags=0x%08x]%s",
-- 
2.13.6


             reply	other threads:[~2017-11-06 22:25 UTC|newest]

Thread overview: 2+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2017-11-06 22:25 Joshua Watt [this message]
2017-11-08 11:32 ` [PATCH] libmount: Allow MNT_FORCE and MNT_DETACH at umount Karel Zak

Reply instructions:

You may reply publicly to this message via plain-text email
using any one of the following methods:

* Save the following mbox file, import it into your mail client,
  and reply-to-all from there: mbox

  Avoid top-posting and favor interleaved quoting:
  https://en.wikipedia.org/wiki/Posting_style#Interleaved_style

* Reply using the --to, --cc, and --in-reply-to
  switches of git-send-email(1):

  git send-email \
    --in-reply-to=20171106222536.9806-1-JPEWhacker@gmail.com \
    --to=jpewhacker@gmail.com \
    --cc=util-linux@vger.kernel.org \
    /path/to/YOUR_REPLY

  https://kernel.org/pub/software/scm/git/docs/git-send-email.html

* If your mail client supports setting the In-Reply-To header
  via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line before the message body.
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox;
as well as URLs for NNTP newsgroup(s).