linux-nfs.vger.kernel.org archive mirror
 help / color / mirror / Atom feed
From: Chuck Lever <chuck.lever@oracle.com>
To: linux-nfs@vger.kernel.org
Subject: [PATCH 2/5] sm-notify: Disable syslog messages when debugging is enabled
Date: Wed, 24 Aug 2011 11:34:03 -0400	[thread overview]
Message-ID: <20110824153403.3138.74467.stgit@matisse.1015granger.net> (raw)
In-Reply-To: <20110824153024.3138.63294.stgit@matisse.1015granger.net>

statd's "-F" flag disables syslog output, and specifies sm-notify's
"-d" option when it runs it.  sm-notify's "-d" option should therefore
also disable syslog output.

Signed-off-by: Chuck Lever <chuck.lever@oracle.com>
---

 utils/statd/sm-notify.c |    6 ++++--
 1 files changed, 4 insertions(+), 2 deletions(-)

diff --git a/utils/statd/sm-notify.c b/utils/statd/sm-notify.c
index 1f490b0..f05eadf 100644
--- a/utils/statd/sm-notify.c
+++ b/utils/statd/sm-notify.c
@@ -395,12 +395,14 @@ usage:		fprintf(stderr,
 		exit(1);
 	}
 
-	xlog_syslog(1);
 	if (opt_debug) {
+		xlog_syslog(0);
 		xlog_stderr(1);
 		xlog_config(D_ALL, 1);
-	} else
+	} else {
+		xlog_syslog(1);
 		xlog_stderr(0);
+	}
 
 	xlog_open(progname);
 	xlog(L_NOTICE, "Version " VERSION " starting");


  parent reply	other threads:[~2011-08-24 15:34 UTC|newest]

Thread overview: 7+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2011-08-24 15:33 [PATCH 0/5] Possible fixes for statd / sm-notify / exportfs Chuck Lever
2011-08-24 15:33 ` [PATCH 1/5] statd: Report count of loaded hosts correctly Chuck Lever
2011-08-24 15:34 ` Chuck Lever [this message]
2011-08-24 15:34 ` [PATCH 3/5] statd: statd_matchhostname() doesn't handle localhost properly Chuck Lever
2011-08-24 15:34 ` [PATCH 4/5] exportfs: matchhostname() " Chuck Lever
2011-08-24 15:34 ` [PATCH 5/5] sm-notify: sm-notify " Chuck Lever
2011-08-29 17:48 ` [PATCH 0/5] Possible fixes for statd / sm-notify / exportfs Steve Dickson

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=20110824153403.3138.74467.stgit@matisse.1015granger.net \
    --to=chuck.lever@oracle.com \
    --cc=linux-nfs@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).