util-linux.vger.kernel.org archive mirror
 help / color / mirror / Atom feed
From: Dave Reisner <d@falconindy.com>
To: util-linux@vger.kernel.org
Subject: Re: [PATCH 1/2] mountpoint: return dev_t from dir_to_device
Date: Sun, 9 Oct 2011 17:23:26 -0400	[thread overview]
Message-ID: <20111009212326.GP782@rampage> (raw)
In-Reply-To: <1318131111-30395-1-git-send-email-dreisner@archlinux.org>

On Sat, Oct 08, 2011 at 11:31:50PM -0400, Dave Reisner wrote:
> The string returned from this function was never of much use other than
> to stat the path when the user requested a major:minor pair beyond the
> true/false exit. Save some processing and directly returning the dev_t
> on success, and an impossible value on failure.
> 
> Signed-off-by: Dave Reisner <dreisner@archlinux.org>
> ---
>  sys-utils/mountpoint.c |   15 +++++++--------
>  1 files changed, 7 insertions(+), 8 deletions(-)
> 

I'll also mention that this fixes an issue with mountpoint that causes
it to throw a false negative when /proc is mounted with a source of
"none". This value is treated specially in libmount and sets the source
to NULL, which makes dir_to_device() incorrectly claim that the directory
is not in fact a mountpoint.

Regards,
dave

  parent reply	other threads:[~2011-10-09 21:23 UTC|newest]

Thread overview: 5+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2011-10-09  3:31 [PATCH 1/2] mountpoint: return dev_t from dir_to_device Dave Reisner
2011-10-09  3:31 ` [PATCH 2/2] mountpoint: fallback on stat when /proc isn't mounted Dave Reisner
2011-10-11  8:52   ` Karel Zak
2011-10-09 21:23 ` Dave Reisner [this message]
2011-10-11  8:21   ` [PATCH 1/2] mountpoint: return dev_t from dir_to_device 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=20111009212326.GP782@rampage \
    --to=d@falconindy.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).