From: Paul Holzinger <pholzing@redhat.com>
To: passt-dev@passt.top
Cc: Paul Holzinger <pholzing@redhat.com>
Subject: [PATCH 1/2] passt: make --quiet set the log level to warning
Date: Thu, 22 Feb 2024 18:17:39 +0100 [thread overview]
Message-ID: <20240222171739.141623-2-pholzing@redhat.com> (raw)
Based on the man page and help output --quiet hides informational
messages. This means that warnings should still be logged. This was
discussed in[1].
[1] https://archives.passt.top/passt-dev/20240216114304.7234a83f@elisabeth/T/#m42652824644973674e84baf9e0bf1d0e88104450
Signed-off-by: Paul Holzinger <pholzing@redhat.com>
---
passt.c | 2 +-
1 file changed, 1 insertion(+), 1 deletion(-)
diff --git a/passt.c b/passt.c
index a90568f..5d7e7c4 100644
--- a/passt.c
+++ b/passt.c
@@ -326,7 +326,7 @@ int main(int argc, char **argv)
if (c.debug)
__setlogmask(LOG_UPTO(LOG_DEBUG));
else if (c.quiet)
- __setlogmask(LOG_UPTO(LOG_ERR));
+ __setlogmask(LOG_UPTO(LOG_WARNING));
else
__setlogmask(LOG_UPTO(LOG_INFO));
--
@@ -326,7 +326,7 @@ int main(int argc, char **argv)
if (c.debug)
__setlogmask(LOG_UPTO(LOG_DEBUG));
else if (c.quiet)
- __setlogmask(LOG_UPTO(LOG_ERR));
+ __setlogmask(LOG_UPTO(LOG_WARNING));
else
__setlogmask(LOG_UPTO(LOG_INFO));
--
2.43.2
next reply other threads:[~2024-02-22 17:18 UTC|newest]
Thread overview: 7+ messages / expand[flat|nested] mbox.gz Atom feed top
2024-02-22 17:17 Paul Holzinger [this message]
2024-02-22 17:17 ` [PATCH 2/2] conf: set the log level much earlier Paul Holzinger
2024-02-23 8:10 ` David Gibson
2024-02-27 14:27 ` Stefano Brivio
2024-02-23 8:12 ` [PATCH 1/2] passt: make --quiet set the log level to warning David Gibson
2024-02-27 14:27 ` Stefano Brivio
2024-02-27 14:27 ` Stefano Brivio
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=20240222171739.141623-2-pholzing@redhat.com \
--to=pholzing@redhat.com \
--cc=passt-dev@passt.top \
/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.
Code repositories for project(s) associated with this public inbox
https://passt.top/passt
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 IMAP folder(s).