summaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
authorChuck Lever <chuck.lever@oracle.com>2011-08-29 13:13:15 -0400
committerSteve Dickson <steved@redhat.com>2011-08-29 13:43:27 -0400
commitd66a9649fdbc75a4bb98e3ee84bf69bd113b739b (patch)
treeb942d06395f1bc4db9f6454fa6041d8d25bf899e
parent7b00283f5a6f8b1d3d1acece1da6df1c30cb6279 (diff)
downloadnfs-utils-d66a9649fdbc75a4bb98e3ee84bf69bd113b739b.tar.gz
nfs-utils-d66a9649fdbc75a4bb98e3ee84bf69bd113b739b.tar.xz
nfs-utils-d66a9649fdbc75a4bb98e3ee84bf69bd113b739b.zip
sm-notify: Disable syslog messages when debugging is enabled
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> Signed-off-by: Steve Dickson <steved@redhat.com>
-rw-r--r--utils/statd/sm-notify.c6
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");