public inbox for gentoo-commits@lists.gentoo.org
 help / color / mirror / Atom feed
From: "William Hubbs" <williamh@gentoo.org>
To: gentoo-commits@lists.gentoo.org
Subject: [gentoo-commits] proj/openrc:openrc-0.11.x commit in: src/rc/
Date: Sun, 28 Oct 2012 21:43:41 +0000 (UTC)	[thread overview]
Message-ID: <1351454561.f53645b7c728492a8d3e6bb7f2fe8bcbce92cf7d.WilliamH@OpenRC> (raw)

commit:     f53645b7c728492a8d3e6bb7f2fe8bcbce92cf7d
Author:     William Hubbs <w.d.hubbs <AT> gmail <DOT> com>
AuthorDate: Wed Oct 24 17:29:29 2012 +0000
Commit:     William Hubbs <williamh <AT> gentoo <DOT> org>
CommitDate: Sun Oct 28 20:02:41 2012 +0000
URL:        http://git.overlays.gentoo.org/gitweb/?p=proj/openrc.git;a=commit;h=f53645b7

mountinfo: respect the -q command line option

Previously, we were setting the quiet flag before the command line was
parsed. Since the flag is only used once, we can just read the
environment variable which is set by the parsing process.

Reported-by: <devurandom <AT> gmx.net>
X-Gentoo-Bug: 439010
X-Gentoo-Bug-URL: http://bugs.gentoo.org/show_bug.cgi?id=439010

---
 src/rc/mountinfo.c |    5 +----
 1 files changed, 1 insertions(+), 4 deletions(-)

diff --git a/src/rc/mountinfo.c b/src/rc/mountinfo.c
index eaace13..43d9c83 100644
--- a/src/rc/mountinfo.c
+++ b/src/rc/mountinfo.c
@@ -390,11 +390,8 @@ mountinfo(int argc, char **argv)
 	char real_path[PATH_MAX + 1];
 	int opt;
 	int result;
-	bool quiet;
 	char *this_path;
 
-	quiet = rc_yesno(getenv("EINFO_QUIET"));
-
 #define DO_REG(_var)							      \
 	if (_var) free(_var);						      \
 	_var = get_regex(optarg);
@@ -483,7 +480,7 @@ mountinfo(int argc, char **argv)
 		if (skip_point_regex &&
 		    regexec(skip_point_regex, s->value, 0, NULL, 0) == 0)
 			continue;
-		if (! quiet)
+		if (! rc_yesno(getenv("EINFO_QUIET")))
 			printf("%s\n", s->value);
 		result = EXIT_SUCCESS;
 	}


             reply	other threads:[~2012-10-28 21:43 UTC|newest]

Thread overview: 2+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2012-10-28 21:43 William Hubbs [this message]
  -- strict thread matches above, loose matches on Subject: below --
2012-10-28 21:43 [gentoo-commits] proj/openrc:openrc-0.11.x commit in: src/rc/ William Hubbs

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=1351454561.f53645b7c728492a8d3e6bb7f2fe8bcbce92cf7d.WilliamH@OpenRC \
    --to=williamh@gentoo.org \
    --cc=gentoo-commits@lists.gentoo.org \
    --cc=gentoo-dev@lists.gentoo.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